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

Attempt to fix PyPy CI #2536

Merged
merged 15 commits into from
Mar 11, 2023
Merged

Attempt to fix PyPy CI #2536

merged 15 commits into from
Mar 11, 2023

Conversation

A5rocks
Copy link
Contributor

@A5rocks A5rocks commented Jan 18, 2023

This should in theory enable the already defined PyPy runs on MacOS and Windows. They never worked!!

This also bumps the @actions/setup-python version we use (the old one errored for nightly PyPy versions & gave us a warning in action runs due to using node 12 vs 16)

@codecov
Copy link

codecov bot commented Jan 18, 2023

Codecov Report

Merging #2536 (393e97b) into master (4b6117b) will increase coverage by 0.00%.
The diff coverage is 75.00%.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #2536   +/-   ##
=======================================
  Coverage   92.45%   92.45%           
=======================================
  Files         118      118           
  Lines       16351    16352    +1     
  Branches     3156     3156           
=======================================
+ Hits        15118    15119    +1     
  Misses       1104     1104           
  Partials      129      129           
Impacted Files Coverage Δ
trio/_core/tests/test_windows.py 17.82% <0.00%> (ø)
trio/socket.py 90.32% <ø> (ø)
trio/_core/tests/tutil.py 86.15% <100.00%> (ø)
trio/tests/test_dtls.py 99.79% <100.00%> (+<0.01%) ⬆️

@webknjaz
Copy link
Member

3332 Segmentation fault (core dumped)

I wonder if this is happening consistently.. Does faulthandler work under PyPy? In some cases, I've found that pytest was crashing due to an old version of its py dependency and pytest-cov was hiding that (the problem only became apparent after disabling it).

@webknjaz
Copy link
Member

By the way, I've just looked into ci.sh and was puzzled after seeing it still uses the deprecated setup.py call for making sdists. On a related note, I've recently made an action that allows running tests from sdist instead of relying on the Git checkout which may miss including important bits needed for testing: https://twitter.com/webknjaz/status/1609252309749440512 — maybe somebody will get to integrating it before I do.

Oh, and it's not clear why not use PyPy that GHA ships for testing...

@webknjaz
Copy link
Member

@webknjaz
Copy link
Member

I wonder if this is happening consistently..

retriggered to verify: https://github.com/python-trio/trio/actions/runs/3945507679/jobs/6766090599.

@A5rocks
Copy link
Contributor Author

A5rocks commented Jan 18, 2023

Oh, and it's not clear why not use PyPy that GHA ships for testing...

I was simply updating ci.sh -- now that I look at it, I see that @actions/python-setup can install a nightly version of pypy! I'll change that out soon.

@webknjaz
Copy link
Member

3332 Segmentation fault (core dumped)

I wonder if this is happening consistently..

I just saw it outside this PR.

@webknjaz
Copy link
Member

On a related note, I've recently made an action that allows running tests from sdist instead of relying on the Git checkout which may miss including important bits needed for testing: twitter.com/webknjaz/status/1609252309749440512 — maybe somebody will get to integrating it before I do.

I've taken a stab at it #2541

@A5rocks
Copy link
Contributor Author

A5rocks commented Jan 23, 2023

It looks like the failure in trio/_core/tests/test_windows.py::test_readinto_overlapped should happen. We pass an immutable bytes object to something that eventually calls ffi.from_buffer(buffer, require_writable=True) (which certainly sounds like it won't accept an immutable bytes object). Why hasn't this errored before?

I will look at the rest of the errors at a later time.

@A5rocks
Copy link
Contributor Author

A5rocks commented Feb 7, 2023

OK I think this is ready for another review. The workflows will error but they shouldn't block required checks. We can figure those out at a later date.

@A5rocks A5rocks requested a review from webknjaz February 7, 2023 03:49
@A5rocks A5rocks marked this pull request as draft February 13, 2023 13:13
@A5rocks
Copy link
Contributor Author

A5rocks commented Feb 14, 2023

Looks like all that needs to happen is macos needs its timeout bumped to like 20 minutes (just like windows) https://github.com/python-trio/trio/actions/runs/4169791936/jobs/7218120369

@A5rocks A5rocks marked this pull request as ready for review February 20, 2023 07:33
@A5rocks
Copy link
Contributor Author

A5rocks commented Feb 20, 2023

Both MacOS tests timed out on test_handshake_over_terrible_network. I don't really have a really accessible macos device but I might be able to try to reproduce this...

Although: it also fails here (kinda): https://github.com/python-trio/trio/actions/runs/4221075009/jobs/7327960276#step:5:1100

The segfault on Windows is something to look into eventually: not now.
I forgot to undo this while switching how nightlys are installed.
@A5rocks
Copy link
Contributor Author

A5rocks commented Mar 8, 2023

I filed an issue about our GC behavior over at https://foss.heptapod.net/pypy/pypy/-/issues/3900; hopefully they can fix our problem or tell us what we're missing.

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

Successfully merging this pull request may close these issues.

3 participants