You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
FIX for "No module named 'public'" during installation (#242)
* Move __version__ to __init__.py
This should solve issue #241, in which setuptools < 46.4.0 tries to
naively import smtp.py (due to version being specified as "attr:
aiosmtpd.smtp.__version__" and barfs when encountering "from public
import public"
Moving __version__ to __init__.py seems to be the wisest -- and most
semantically accurate -- decision. Not only can setuptools < 46.4.0
simply do a naive import of __init__.py (which contains no deps), but
this signifies the version number applies to the _whole_ aiosmtpd
package instead of just the smtp.py module.
This impacts the following files
* setup.cfg -- scan inside aiosmtpd instead of aiosmtpd.smtp
* smtp.py -- it now needs to import
* conf.py -- no longer scan smtp.py; import from __init__ instead
* Add Compatibility Test
In this case, ensure __version__ from __init__.py is exact same object
as __version__ from smtp.py
* Update NEWS.rst
0 commit comments