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

eventlet breaks select.poll() #608

Closed
IamFive opened this issue Apr 11, 2020 · 2 comments
Closed

eventlet breaks select.poll() #608

IamFive opened this issue Apr 11, 2020 · 2 comments

Comments

@IamFive
Copy link

IamFive commented Apr 11, 2020

Hi, i try to install openstack ironic on ubuntu 18.04. And eventlet lib seems breaking things. But it's wierd that others do not have this issue.

I can simply reproduce it by:

Python 3.6.9 (default, Nov  7 2019, 10:44:02) 
[GCC 8.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import eventlet
>>> 
>>> eventlet.patcher.monkey_patch()
>>> import select
>>> select.poll
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: module 'select' has no attribute 'poll'
>>> eventlet.version_info
(0, 25, 0)
>>> 
@jstasiak
Copy link
Contributor

This is intentional, see f63165c. The client code is expected to check if select.poll (or other method) exists and fall back to select.select (or use the selectors module that does that behind the scenes).

@IamFive
Copy link
Author

IamFive commented Apr 11, 2020

thanks for the answer. will check why select.poll is called directly then.

@IamFive IamFive closed this as completed Apr 11, 2020
tito added a commit to tito/docker-py that referenced this issue May 16, 2023
…form check

The implementation done in docker#2865 is breaking usage of docker-py library within eventlet.
As per the Python `select.poll` documentation (https://docs.python.org/3/library/select.html#select.poll) and eventlet select removal advice (eventlet/eventlet#608 (comment)), it is preferable to use an implementation based on the availability of the `poll()` method that trying to check if the platform is `win32`.

Fixes docker#3131

Signed-off-by: Mathieu Virbel <[email protected]>
milas pushed a commit to docker/docker-py that referenced this issue Jun 1, 2023
Check if poll attribute exists on select module instead of win32 platform check

The implementation done in #2865 is breaking usage of docker-py library within eventlet.
As per the Python `select.poll` documentation (https://docs.python.org/3/library/select.html#select.poll) and eventlet select removal advice (eventlet/eventlet#608 (comment)), it is preferable to use an implementation based on the availability of the `poll()` method that trying to check if the platform is `win32`.

Fixes #3131

Signed-off-by: Mathieu Virbel <[email protected]>
felixfontein added a commit to felixfontein/community.docker that referenced this issue Oct 7, 2023
Check if poll attribute exists on select module instead of win32 platform check

The implementation done in #2865 is breaking usage of docker-py library within eventlet.
As per the Python `select.poll` documentation (https://docs.python.org/3/library/select.html#select.poll) and eventlet select removal advice (eventlet/eventlet#608 (comment)), it is preferable to use an implementation based on the availability of the `poll()` method that trying to check if the platform is `win32`.

Fixes docker/docker-py#3131

Cherry-picked from docker/docker-py@78439eb

Co-authored-by: Mathieu Virbel <[email protected]>
felixfontein added a commit to ansible-collections/community.docker that referenced this issue Oct 8, 2023
* vendored Docker SDK for Python code: volume: added support for bind propagation

https://docs.docker.com/storage/bind-mounts/#configure-bind-propagation

Cherry-picked from docker/docker-py@bea6322

Co-authored-by: Janne Jakob Fleischer <[email protected]>
Co-authored-by: Milas Bowman <[email protected]>

* vendored Docker SDK for Python code: fix: eventlet compatibility

Check if poll attribute exists on select module instead of win32 platform check

The implementation done in #2865 is breaking usage of docker-py library within eventlet.
As per the Python `select.poll` documentation (https://docs.python.org/3/library/select.html#select.poll) and eventlet select removal advice (eventlet/eventlet#608 (comment)), it is preferable to use an implementation based on the availability of the `poll()` method that trying to check if the platform is `win32`.

Fixes docker/docker-py#3131

Cherry-picked from docker/docker-py@78439eb

Co-authored-by: Mathieu Virbel <[email protected]>

* vendored Docker SDK for Python code: fix: use response.text to get string rather than bytes

Adjusted from docker/docker-py@0618951

Co-authored-by: Mehmet Nuri Deveci <[email protected]>
Co-authored-by: Milas Bowman <[email protected]>

* vendored Docker SDK for Python code: Fix missing asserts or assignments

Cherry-picked from docker/docker-py@0566f12

Co-authored-by: Aarni Koskela <[email protected]>

---------

Co-authored-by: Janne Jakob Fleischer <[email protected]>
Co-authored-by: Milas Bowman <[email protected]>
Co-authored-by: Mathieu Virbel <[email protected]>
Co-authored-by: Mehmet Nuri Deveci <[email protected]>
Co-authored-by: Aarni Koskela <[email protected]>
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

No branches or pull requests

2 participants