fix auto-generating the version file

After the latest commit, I was getting an error when trying to run cdist. It looks like there was some code missing when build-helper tried to generate the version.py file.