nvector icon indicating copy to clipboard operation
nvector copied to clipboard

Suggestion: make `Cartopy` and opt-in dependency

Open freol35241 opened this issue 3 years ago • 1 comments

As of 0.7.7, Cartopy is a required dependency of nvector. This is sometimes problematic since Cartopy does not provide ready-built wheels on pypi, thus requiring every user to have a proper build environment (including a build of GEOS) to do pip install nvector.

My suggestion would be to put the plotting part of nvector as a an optional dependency so that users can do pip install nvector to get the core functionality or pip install nvector[plots] (or similar) to also require Cartopy (and perhaps matplotlib).

Right now, the "easy way out" for me is to do: pip install "nvector<=0.7.6"

freol35241 avatar Jan 21 '22 08:01 freol35241

Hello @freol35241,

I have taken the liberty to fork the nvector package into a new PyPI package titled envector. The envector package is intended as a drop-in replacement with minimal changes in your source code as no methods and classes have been removed since the fork. For example, this is a valid snippet

import envector as nv
wgs84 = nv.FrameE(name='WGS84')

As for this issue, I believe you have a valid point. I think this change is appropriate for "envector" and welcome the suggestion. I politely request that open the same issue at the envector homepage in order for the package to get more public awareness.

Thank you for your attention.

EDIT: The envector package dependency specifications set Cartopy>=0.22.0", which include wheel files. With that said, Cartopy should not be strictly required as the case when it is missing is supported in both nvector and envector.

mhogan-nwra avatar Sep 09 '24 21:09 mhogan-nwra

Fixed in SHA-1: e6596f541080a126534cecc00912ce790e14d078

pbrod avatar Oct 04 '24 06:10 pbrod