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

pyshp version lock limits usage with cartopy #234

Open
gcoyle83 opened this issue Dec 18, 2024 · 3 comments · May be fixed by #235
Open

pyshp version lock limits usage with cartopy #234

gcoyle83 opened this issue Dec 18, 2024 · 3 comments · May be fixed by #235

Comments

@gcoyle83
Copy link

gcoyle83 commented Dec 18, 2024

Issue description

This may be a very edge case issue for you all, and I want to lead with a thanks for the work on this library. That said, I tend to use cartopy to develop maps for displaying geospatial data. Cartopy requires pyshp>=2.3, while swmmio appears to be locked to pyshp==2.1.0, which is going on six years old. Understanding your core objective is maintaining your own library, not compatibility with arbitrary others, is it a big ask to update to the latest pyshp to resolve this?

To reproduce

Build env with basic dependencies:

name: test_env
channels:
 - conda-forge
dependencies:
 - python==3.11 
 - cartopy 
 - jupyter 
 - matplotlib>=3.6 
 - pip 
 - pyproj>=3.3.1 
 - pyshp>=2.3 
 - shapely>=1.8 
 - pip:
    - pyswmm[swmm5.2.3]

Then run example from cartopy docs:

import cartopy.crs as ccrs
import matplotlib.pyplot as plt
ax = plt.axes(projection=ccrs.PlateCarree())
ax.coastlines()
plt.show()

This should work. Add swmmio to pip installs, and then it will not work, throwing a ShapefileException error due to pyshp version lock.

@aerispaha
Copy link
Member

@gcoyle83 thanks for raising this! I don't recall any reason why we're locked on an old version of pyshp. I can run some tests to see if this causes any problems. If it doesn't, I think we can make this change in the next release.

@aerispaha
Copy link
Member

@gcoyle83, seems like upgrading pyshp is totally doable. I've got this ready in #236

@gcoyle83
Copy link
Author

Thanks for the quick response to this!

@aerispaha aerispaha linked a pull request Dec 19, 2024 that will close this issue
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.

2 participants