Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rebuild multidict using cython 0.29.0 #304

Closed
asottile opened this issue Nov 19, 2018 · 13 comments
Closed

Rebuild multidict using cython 0.29.0 #304

asottile opened this issue Nov 19, 2018 · 13 comments
Labels

Comments

@asottile
Copy link
Contributor

Describe the bug

This will resolve #79 and #101

To Reproduce

script

rm -rf venv
virtualenv venv -ppython3.6
venv/bin/pip install multidict
venv/bin/python -Werror -c 'import multidict'

output

...
Successfully installed multidict-4.4.2
$ venv/bin/python -Werror -c 'import multidict'
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/tmp/t/venv/lib/python3.6/site-packages/multidict/__init__.py", line 23, in <module>
    from ._multidict import (MultiDictProxy,
  File "multidict/_multidict.pyx", line 9, in init multidict._multidict
ImportWarning: can't resolve package from __spec__ or __package__, falling back on __name__ and __path__

Expected behavior

(silence)

Logs/tracebacks

see above

Your version of the Python

$ ./venv/bin/python --version --version
Python 3.6.6 (default, Sep 12 2018, 18:26:19) 
[GCC 8.0.1 20180414 (experimental) [trunk revision 259383]]

Your version of the multidict distribution

see above

Additional context

The current wheel is built against 0.28.5:

$ grep Generated !$
grep Generated venv/lib/python3.6/site-packages/multidict/_multidict.c
/* Generated by Cython 0.28.5 */

Building from source against 0.28.5 produces the error:

rm -rf venv
virtualenv venv -ppython3.6
venv/bin/pip install cython==0.28.5
git -C multidict clean -fxfd
venv/bin/pip install ./multidict
venv/bin/python -Werror -c 'import multidict'
...
$ venv/bin/python -Werror -c 'import multidict'
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/tmp/t/venv/lib/python3.6/site-packages/multidict/__init__.py", line 23, in <module>
    from ._multidict import (MultiDictProxy,
  File "multidict/_multidict.pyx", line 9, in init multidict._multidict
ImportWarning: can't resolve package from __spec__ or __package__, falling back on __name__ and __path__

Building from source against 0.29.0:

rm -rf venv
virtualenv venv -ppython3.6
venv/bin/pip install cython==0.29.0
git -C multidict clean -fxfd
venv/bin/pip install ./multidict
venv/bin/python -Werror -c 'import multidict'
...
$ venv/bin/python -Werror -c 'import multidict'
$ 

proper silence!

@aio-libs-bot

This comment has been minimized.

@aio-libs-bot
Copy link

GitMate.io thinks possibly related issues are #178 (Decorate multidict clases by @cython.final), #183 (Issue with multidict installation with version 3.3.0), #140 (multidict 3.2.0 won't install properly on docker), #280 (Can't install multidict 4.4.0 in docker alpine image), and #249 (Get rid of cython).

@webknjaz
Copy link
Member

Cool! Thanks for the explanation. I'll check whether we can trigger new build right now :)

@asottile
Copy link
Contributor Author

skimming through the scripts it looks like all that's needed is a version bump and a release given this already has cython==0.29

@webknjaz
Copy link
Member

Yes, that's bumped by pyup bot but PyPI release still needs to be triggered manually.

Previously tagged version used v0.28.5: https://github.com/aio-libs/multidict/blob/b33b734/requirements/wheel.txt#L1

@webknjaz
Copy link
Member

I've triggered the build in CI. Should be done by morning (...or evening for you?)

@asottile
Copy link
Contributor Author

hype! thanks a ton 👍

@asottile
Copy link
Contributor Author

Confirming it is fixed, thanks again!

$ pip install multidict
Collecting multidict
  Downloading https://files.pythonhosted.org/packages/64/32/2e914f636f557e72399556079c2f20af19aa91d525f8cfef663664500107/multidict-4.5.0-cp36-cp36m-manylinux1_x86_64.whl (309kB)
    100% |████████████████████████████████| 317kB 9.2MB/s 
Installing collected packages: multidict
Successfully installed multidict-4.5.0
$ python3 -Werror -c 'import multidict'
$

@webknjaz
Copy link
Member

You're welcome :)

@Callek
Copy link

Callek commented Nov 20, 2018

Awesome! thanks for the fast turnaround after I reported it (against the wrong package)!

@asvetlov
Copy link
Member

@webknjaz please update changenote and edit https://github.com/aio-libs/multidict/releases/tag/v4.5.0 page

@webknjaz
Copy link
Member

@asvetlov I've copied changelog there. Is it good now?

@asvetlov
Copy link
Member

Perfect. Thanks.
Would be nice to see a record about getting rid of import warning but I can live with the current text :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants