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

Add official support for Python 3.12 #3287

Closed
astrojuanlu opened this issue Nov 8, 2023 · 5 comments · Fixed by #3587
Closed

Add official support for Python 3.12 #3287

astrojuanlu opened this issue Nov 8, 2023 · 5 comments · Fixed by #3587
Assignees
Labels
Issue: Feature Request New feature or improvement to existing feature

Comments

@astrojuanlu
Copy link
Member

astrojuanlu commented Nov 8, 2023

Description

Kedro itself probably works on Python 3.12 already, it would be nice to declare official support.

However, installing Kedro is one thing, but installing the typical dependencies might not be straightforward. For example, I just tested the spaceflights starter and most of the dependencies have already published precompiled wheels for Python 3.12 (at least for M1 Mac), but two of them are still problematic as of today:

Context

#2815 was already completed, but officially Kedro does not support Python 3.12 yet.

You can use Kedro on Python 3.12 by manually disabling the warning.

Possible Implementation

Wait a bit until at least the spaceflights starter can be safely installed in most mainstream platforms.

Possible Alternatives

Declare Python 3.12 support already, at the cost of creating some grievance of users that then proceed to install some dependencies.

@astrojuanlu
Copy link
Member Author

aiohttp 3.9.0 released

@astrojuanlu
Copy link
Member Author

pyzmq has a fix incoming zeromq/pyzmq#1913

@astrojuanlu
Copy link
Member Author

One last transitive dependency of aiohttp, multidict, is missing 3.12 wheels aio-libs/multidict#887

@astrojuanlu
Copy link
Member Author

All transitive dependencies of Kedro have official support for 3.12. Let's go!

astrojuanlu added a commit that referenced this issue Feb 2, 2024
Close #3287.

Signed-off-by: Juan Luis Cano Rodríguez <juan_luis_cano@mckinsey.com>
astrojuanlu added a commit that referenced this issue Feb 12, 2024
Close #3287.

Signed-off-by: Juan Luis Cano Rodríguez <juan_luis_cano@mckinsey.com>
@astrojuanlu
Copy link
Member Author

Now the problem is in the Kedro tests themselves:

@noklam noklam moved this to To Do in Kedro Framework Mar 4, 2024
@merelcht merelcht moved this from To Do to In Progress in Kedro Framework Mar 7, 2024
@astrojuanlu astrojuanlu moved this from In Progress to In Review in Kedro Framework Mar 8, 2024
AhdraMeraliQB added a commit that referenced this issue Mar 12, 2024
* Add official support for Python 3.12

Close #3287.

Signed-off-by: Juan Luis Cano Rodríguez <juan_luis_cano@mckinsey.com>

* Mark broken test as xfail

Signed-off-by: Juan Luis Cano Rodríguez <juan_luis_cano@mckinsey.com>

* Overwrite inherited get to use __getitem__

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Appease mypy

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Fix test

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Fix test coverage

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Use spy instead of patch

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Make comment more clear

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

---------

Signed-off-by: Juan Luis Cano Rodríguez <juan_luis_cano@mckinsey.com>
Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>
Signed-off-by: Ahdra Merali <90615669+AhdraMeraliQB@users.noreply.github.com>
Co-authored-by: Ahdra Merali <ahdra.merali@quantumblack.com>
Co-authored-by: Ahdra Merali <90615669+AhdraMeraliQB@users.noreply.github.com>
@github-project-automation github-project-automation bot moved this from In Review to Done in Kedro Framework Mar 12, 2024
AhdraMeraliQB added a commit that referenced this issue Mar 15, 2024
* Add official support for Python 3.12

Close #3287.

Signed-off-by: Juan Luis Cano Rodríguez <juan_luis_cano@mckinsey.com>

* Mark broken test as xfail

Signed-off-by: Juan Luis Cano Rodríguez <juan_luis_cano@mckinsey.com>

* Overwrite inherited get to use __getitem__

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Appease mypy

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Fix test

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Fix test coverage

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Use spy instead of patch

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Make comment more clear

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Remove redundant test assert

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Remove redundant variable

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Fix broken docs link

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Fix broken docs link

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Update docstring to reflect test

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Add test to ensure deduplication

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

* Trim test

Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>

---------

Signed-off-by: Juan Luis Cano Rodríguez <juan_luis_cano@mckinsey.com>
Signed-off-by: Ahdra Merali <ahdra.merali@quantumblack.com>
Signed-off-by: Ahdra Merali <90615669+AhdraMeraliQB@users.noreply.github.com>
Co-authored-by: Juan Luis Cano Rodríguez <juan_luis_cano@mckinsey.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue: Feature Request New feature or improvement to existing feature
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants