-
Notifications
You must be signed in to change notification settings - Fork 214
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
Disallow creation of non-CRS (eg pipeline) in CRS class #267
Comments
I think just need to check that |
Not sure if that is enough, as you have also There is also |
The |
I have a less than optimal implementation in #263. |
…s; update CRS repr) (#263) * updated CRS repr for clarity; added BaseCRS for datum/ellipsoid/prime_meridian * add check to ensure input to CRS is a CRS (issue #267) * added support for compound CRS (issue #265) * updated repr to use EPSG code with 100% confidence for input & removed EPSG in repr * added docstrings for cython classes; cleaned up unused attributes in crs cython classes; added examples for CRS usage * fixed setting the coordinate operation name * change boolean like objects from int to bool * check if bound crs is geographic (issue #274) * added support for from_auth to CRS,Ellipsoid,PrimeMeridian,CoordinateOperation,Datum classes
I am going to close this as the solution is merged into master. Thanks for bringing up the idea! |
From discussion with @snowman2
Currently, you can create a
CRS
object from eg a proj pipeline:which does not give you an actual CRS, but generic coordinate transformation. So it is probably a good idea to disallow this in the construction of a
CRS
object.For this specific case we could check for
proj=pipeline
in the string. Or more in general we could check theproj_type
and raise an error if it is not one of the CRS types (we could still do the first pipeline check as well to have a better error message for that specific case).The text was updated successfully, but these errors were encountered: