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

Python 3.7 compatibility issue introduced by release 1.3.0 #1469

Closed
nicolas-seichepine opened this issue Jun 28, 2023 · 7 comments · Fixed by #1472
Closed

Python 3.7 compatibility issue introduced by release 1.3.0 #1469

nicolas-seichepine opened this issue Jun 28, 2023 · 7 comments · Fixed by #1472

Comments

@nicolas-seichepine
Copy link

Hi,

If I understand correctly, latest release should work with python 3.7

In the meantime, this specific line introduced in release 1.3.0 breaks compatibility (ImportError: cannot import name '_MAX_WINDOWS_WORKERS' from 'concurrent.futures.process')

@imatiach-msft
Copy link

I'm seeing a similar error on windows python 3.7:

File "C:\Miniconda\envs\test\lib\site-packages\joblib\externals\loky\backend\popen_loky_win32.py", line 153, in main
_winapi.SYNCHRONIZE | _winapi.PROCESS_DUP_HANDLE, False, parent_pid
AttributeError: module '_winapi' has no attribute 'SYNCHRONIZE'

trying to pin joblib < 1.3.0 in the tests for now...

@glutamatt
Copy link

some hints :
image
image

@1C4nfaN
Copy link

1C4nfaN commented Jun 29, 2023

the version cpython<=3.7.3 does not define _MAX_WINDOWS_WORKERS

@tomMoral
Copy link
Contributor

Thanks a lot for the report and investigations.
I opened a PR to fix this in loky (joblib/loky#408). I will try to do a bug fix release asap, feel free to let us know if anything else come up before this.

@imatiach-msft
Copy link

Seems my problem is a bit different, I created a new issue here:

joblib/loky#411

@tomMoral
Copy link
Contributor

The problem should be resolved on unix platform with the release 1.3.1.
Let us know if more problem persists.

For windows user, a potential way around is to use the spawn processes in `loky, which should provide a relatively good support but might still have some issues with controlling the C-level parallelism for instance with numpy.

from joblib.externals.loky.backend.context import set_start_method

set_start_method('spawn')

@imatiach-msft
Copy link

imatiach-msft commented Jun 29, 2023

I just pinned to joblib<1.3.0 on python 3.7 & windows platform and it works for now. I think most of our users are on unix anyway and python 3.8 or greater but we like to exhaustively test every python/platform/oss package combination.

dev-rinchin added a commit to sb-ai-lab/LightAutoML that referenced this issue Jul 6, 2023
DESimakov pushed a commit to sb-ai-lab/LightAutoML that referenced this issue Jul 12, 2023
* time_series config and tutorial + bug fixes

* change github workflow poetry version

* change github workflow CI poetry version

* upper bound statsmodels version

* fix tutiral's images

* fix joblib error for python3.7 on windows

joblib/joblib#1469

---------

Co-authored-by: Rinchin <57899558+dev-rinchin@users.noreply.github.com>
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 a pull request may close this issue.

5 participants