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

Support Python 3.11 #32

Closed
mfitz opened this issue Dec 14, 2022 · 0 comments · Fixed by #35
Closed

Support Python 3.11 #32

mfitz opened this issue Dec 14, 2022 · 0 comments · Fixed by #35
Assignees
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@mfitz
Copy link
Contributor

mfitz commented Dec 14, 2022

OSMOX does not currently pip install successfully in a Python 3.11 environment on Ubuntu.

I was able to make pip install succeed by:

  • Upgrading the following dependencies in requirements.txt:
$ diff requirements.txt requirements-3.11.txt

< osmium==3.1.0
---
> osmium==3.5.0

< pyproj==3.1.0
---
> pyproj==3.4.1
  • Installing the native cmake library required by the upgraded osmium version (this will need documenting in README and adding to both Dockerfile and the CI build workflow):
sudo apt-get install cmake

We will need to upgrade library versions as necessary, but we should also try to find a set of dependencies that work in both Python 3.7 and Python 3.11. If we cannot do that, we will need to clearly flag the new Python version dependency, make a pre-upgrade release of OSMOX, merge the upgrade changes, then make a post-upgrade release. I would regard these two releases as differing major versions in semver terms.

If the unit test performance is anything to go by (and it may not be), we could potentially see a performance improvement in 3.11:

(osmox-3.7.6) arup@workbox-michael:~/osmox$ loops 5 ./scripts/code-coverage.sh | grep "passed, "
======================= 48 passed, 66 warnings in 3.48s ========================
======================= 48 passed, 66 warnings in 3.52s ========================
======================= 48 passed, 66 warnings in 3.54s ========================
======================= 48 passed, 66 warnings in 3.57s ========================
======================= 48 passed, 66 warnings in 3.60s ========================


(osmox-3.11.0) arup@workbox-michael:~/osmox$ loops 5 ./scripts/code-coverage.sh | grep "passed in"
============================== 48 passed in 1.50s ==============================
============================== 48 passed in 1.50s ==============================
============================== 48 passed in 1.52s ==============================
============================== 48 passed in 1.52s ==============================
============================== 48 passed in 1.51s ==============================
@mfitz mfitz added enhancement New feature or request good first issue Good for newcomers labels Dec 14, 2022
@val-ismaili val-ismaili self-assigned this Jan 19, 2023
@val-ismaili val-ismaili linked a pull request Jan 19, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants