-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Python 3.4+: use os.set_inheritable + os.set_blocking in place of unreadable fcntl calls #3210
base: master
Are you sure you want to change the base?
Conversation
3ab0385
to
bc4fc46
Compare
Not disagreeing about this change but this must be validated on BSD. I think we need to add FreeBSD to our test platform to ensure it works there. (an dmaybe other OpenBSD). |
b5a25e9
to
4831ef3
Compare
@benoitc Happy with pulling Neil Pang's vm images? Those work with very little setup required for FreeBSD, OpenBSD and illumos (no prebuilt gevent though). Though the Github file still needs review by someone more proficient with that:
|
5632dc0
to
a452f12
Compare
f8bda39
to
0d03ef2
Compare
reduces duplicate workflow runs in forks
using https://github.com/vmactions workaround greenlet installation on OmniOS v11: libev assumes inotify.h must be Linux. make autoconf stop offering it.
0d03ef2
to
02f9d03
Compare
gunicorn invocation now matches between the two similar tests nginx needs worker=off to shut down when signaled
gevent worker on OmniOS py3.12/gcc14 fails with: AttributeError: module 'threading' has no attribute 'get_native_id' skip slow benchmark on PyPy
on gevent 24.10.1 to 24.11.1 gevent worker on OmniOS py3.12/gcc14 fails with: AttributeError: module 'threading' has no attribute 'get_native_id' see gevent/gevent#2053
6402a5c
to
ff48a1f
Compare
i will look at this branch but I am questionning the goal pursued there. One of the point of keeping low level though is to not depends on how one external dev think things should work. Knowing and controlling low level access allows us to understand and track more accurately some issues. Thoughts? |
Goals:
The first goal is to remove code that is difficult to diagnose for purely historical, no longer applicable, reasons. cPython did not offer these shorthands back then. Now it does. We never gained or lost any control over that particular low-level API, because either it will do what we expect, or worse: it will pretend to offer matching API, but with differences only observable elsewhere. For those cases, I am all in favor of adding a generous amount of verbosity in clearly platform-specific branches e.g. extend error handlers: pajod@7475a75
Specifically, I would like to stop caring whether Windows thinks one should call incompatible |
We should cleanup those rather unreadable low-level fcntl calls. The stdlib provides single-call functions for these now.
(Replacement is not 100% equivalent, as they might call
ioctl(.., FIO.., NULL)
instead, but I see no reason we should care.)Suggested order:
.fileno()
suffixes that might to be dropped