jheled / royalur

The (Classic) Royal Game of Ur
GNU Affero General Public License v3.0
1 stars 2 forks source link

setup.py Can't import a module that is not yet installed #1

Closed oysteijo closed 6 years ago

oysteijo commented 6 years ago

Hi, Thanks for this effort. I love it. There is a tiny bug in 'setup.py. If you insetup.py` do:

from royalur import __version__

The import system will also try to import all the submodule in __init__.py, which are not yet available for new users/developers, You hence have to extract the __version__ from __init__.py (or whatever file that contains the version information) without importing the module from setup.py.

Some ideas from stack overflow: https://stackoverflow.com/questions/2058802/how-can-i-get-the-version-defined-in-setup-py-setuptools-in-my-package

(I manually hacked this the dirty way)

Thanks, Øystein

jheled commented 6 years ago

I removed the import from setup and duplicated the version number.