aio-libs / aiodns

Simple DNS resolver for asyncio
https://pypi.python.org/pypi/aiodns
MIT License
532 stars 69 forks source link

aiodns==1.1.0 wheel issue #20

Closed hellysmile closed 8 years ago

hellysmile commented 8 years ago

It seems aiodns==1.1.0 wheel from pypi is build with trollius requirement via setup.py check for Python less then 3.3, which produces an issue for any python version

python --version
Python 3.5.2
pip install aiodns
Collecting aiodns
  Downloading aiodns-1.1.0-py2.py3-none-any.whl
Collecting trollius (from aiodns)
Requirement already satisfied (use --upgrade to upgrade): pycares>=1.0.0 in ./env/lib/python3.5/site-packages (from aiodns)
Requirement already satisfied (use --upgrade to upgrade): six in ./env/lib/python3.5/site-packages (from trollius->aiodns)
Installing collected packages: trollius, aiodns
Successfully installed aiodns-1.1.0 trollius-2.1

Installation directly from tar.gz (sdist) works as expected

pip install https://pypi.python.org/packages/e1/3a/855c8e79e626ca43d7c28072676bf5bf5576a91a987dc39a44c04da6e761/aiodns-1.1.0.tar.gz#md5=ee3fc86fc11296a9887a92870bdfd0b1
Collecting https://pypi.python.org/packages/e1/3a/855c8e79e626ca43d7c28072676bf5bf5576a91a987dc39a44c04da6e761/aiodns-1.1.0.tar.gz#md5=ee3fc86fc11296a9887a92870bdfd0b1
  Using cached aiodns-1.1.0.tar.gz
Requirement already satisfied (use --upgrade to upgrade): pycares>=1.0.0 in ./env/lib/python3.5/site-packages (from aiodns==1.1.0)
Building wheels for collected packages: aiodns
  Running setup.py bdist_wheel for aiodns ... done
  Stored in directory: ZzzZzZzzZz
Successfully built aiodns
Installing collected packages: aiodns
Successfully installed aiodns-1.1.0
saghul commented 8 years ago

Hum, looks like the check for trollius in setup.py adds it as a hard dependency :-S Do you know a way around this? (other than dropping the wheel, that is)

hellysmile commented 8 years ago

What about wheel per major Python version?

saghul commented 8 years ago

Since this is a pure python package I guess there is not much advantage in wheels anyway. One wheel per major Python version is too much. I'll drop the wheel if I can't find a way around it.

saghul commented 8 years ago

Ah, looks like it can be done: https://wheel.readthedocs.io/en/latest/#defining-conditional-dependencies

I'll take of it tomorrow. Thanks a lot for the report!