-
Notifications
You must be signed in to change notification settings - Fork 23
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
Update dependency shapely to v2 #1642
Conversation
Current strategy: Then reevaluate the upgrade to Shapely 2. |
cc5bc9d
to
e81fb34
Compare
e81fb34
to
619d2aa
Compare
Edited/Blocked NotificationRenovate will not automatically rebase this PR, because it does not recognize the last commit author and assumes somebody else may have edited the PR. ⚠ Warning: custom changes will be lost. |
It seems Shapely 2.0 raises a different exception type than Shapely 1.8: The type of exception in our test case is shapely.errors.GEOSException, The behavior seems equivalent, so I adapted the test case. Further reviews appreciated. |
Codecov Report
@@ Coverage Diff @@
## master #1642 +/- ##
=======================================
Coverage 77.50% 77.50%
=======================================
Files 127 127
Lines 5209 5209
=======================================
Hits 4037 4037
Misses 1172 1172
Flags with carried forward coverage won't be shown. Click here to find out more. 📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good. Thanks.
I did the following review actions:
- look over the code changes
- read the migration doc for shapely 1.8/2.0 https://shapely.readthedocs.io/en/stable/migration.html
- checked use of exceptions in the shapely source code (tests)
Everything tells me the current use of shapely (and the caught exception) is fine and I could not find any deprecations.
We should continue checking for deprecation warnings in the test outputs.
@jwkaltz I will test it in our environment. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I made some tests in our environment and did not encounter any differences to version 1.8. I remember (or think to) that there was a discussion about shapely at the beginning of working on pyramid oereb v2. Was this related to shapely and python version 3.7 or was it related to the handling of not valid geometries in different versions of shapely?
Yes, there were some differences in behaviour for older versions, summarized here: #1111 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Then I have no objections. Thanks.
This PR contains the following updates:
==1.8.5.post1
->==2.0.0
Release Notes
shapely/shapely
v2.0.0
Compare Source
Shapely version 2.0.0 is a major release featuring a complete refactor of the
internals and new vectorized (element-wise) array operations providing
considerable performance improvements.
For a full changelog, see
https://shapely.readthedocs.io/en/latest/release/2.x.html#version-2-0-0
Relevant changes in behaviour compared to 2.0rc3:
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate. View repository job log here.