-
Notifications
You must be signed in to change notification settings - Fork 795
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
Experimental support for PyPy 3.6 #1092
Conversation
4f57ee3
to
d6bf8ef
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you!
It looks like you forgot to remove ci/actions/test.sh
?
Co-authored-by: Yuji Kanagawa <[email protected]>
Good catch, removed now. I mistakenly thought it was used in the |
pub static mut PyExc_EnvironmentError: *mut PyObject; | ||
#[cfg(not(all(windows, PyPy)))] | ||
pub static mut PyExc_IOError: *mut PyObject; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since IOError
is just a alias of OSError
on Python 3, I think we can expose PyExc_IOError
as PyPyExc_OSError
?
Use case: https://github.com/milesgranger/pyrus-cramjam/runs/2227542030?check_suite_focus=true
Installing collected packages: cramjam
Successfully installed cramjam-2.2.0
Traceback (most recent call last):
File "<string>", line 1, in <module>
ImportError: /opt/hostedtoolcache/PyPy/3.6.12/x64/site-packages/cramjam.pypy36-pp73-x86_64-linux-gnu.so: undefined symbol: PyExc_IOError
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, but does it seem that PyPy takes a different strategy for that error?
https://foss.heptapod.net/pypy/pypy/-/blob/branch/default/pypy/module/exceptions/moduledef.py#L21
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure, but it seems to be the same on the Python side on my local PyPy installation.
Python 3.7.10 (7035471788c8, Mar 19 2021, 02:02:14)
[PyPy 7.3.5-alpha0 with GCC Apple LLVM 12.0.0 (clang-1200.0.32.29)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
And now for something completely different: ``finally, mercurial migration is
happening!''
>>>> IOError
<class 'OSError'>
>>>> OSError
<class 'OSError'>
>>>> IOError is OSError
True
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually it is the same on pypy 3.6 and 3.7 branch https://foss.heptapod.net/pypy/pypy/-/blob/branch/py3.7/pypy/module/exceptions/moduledef.py#L31
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, I got it, thanks.
I added Windows and MacOS actions builds for PyPy. This caused quite a bit of pain; eventually I did manage to get things building.
Issues became apparent on pypy initially when I tried to use it for PyO3/setuptools-rust#78