Fix hole in __version__ lookup logic

If the verson JSON file didn't exist and the setup.py file wasn't
available you fell through the logic hole and got an AttributeError.