Added nicer versioning and error reporting in preparation for gem release