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

REF: Use upper case EPSG code when creating CRS #1162

Merged
merged 1 commit into from Oct 14, 2022

Conversation

snowman2
Copy link
Member

@snowman2 snowman2 commented Oct 14, 2022

The EPSG database uses the uppercase version. This is for consistency with to_authority.

@snowman2 snowman2 added this to the 3.4.1 milestone Oct 14, 2022
@@ -147,7 +147,7 @@ def _prepare_from_authority(auth_name: str, auth_code: Union[str, int]):


def _prepare_from_epsg(auth_code: Union[str, int]):
return _prepare_from_authority("epsg", auth_code)
return _prepare_from_authority("EPSG", auth_code)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the main change when creating CRS from_epsg integer.

@codecov
Copy link

codecov bot commented Oct 14, 2022

Codecov Report

Merging #1162 (acc0992) into main (837d965) will not change coverage.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##             main    #1162   +/-   ##
=======================================
  Coverage   96.18%   96.18%           
=======================================
  Files          18       18           
  Lines        1703     1703           
=======================================
  Hits         1638     1638           
  Misses         65       65           
Impacted Files Coverage Δ
pyproj/proj.py 97.72% <ø> (ø)
pyproj/transformer.py 94.95% <ø> (ø)
pyproj/crs/crs.py 98.05% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@snowman2 snowman2 merged commit b5166bc into pyproj4:main Oct 14, 2022
@snowman2 snowman2 deleted the upper_epsg branch October 14, 2022 15:03
klssmith added a commit to alphagov/notifications-utils that referenced this pull request Dec 15, 2022
Version 3.4.1 of pyproj changed the ESPG codes to be upper case, which
means that our tests now fail (pyproj4/pyproj#1162).

This change updates our code to also use upper case codes, and bumps the
minimum version of pyproj to ensure that we're always using a version
which also uses the upper case codes.
klssmith added a commit to alphagov/notifications-utils that referenced this pull request Dec 15, 2022
Version 3.4.1 of pyproj changed the ESPG codes to be upper case, which
means that our tests now fail (pyproj4/pyproj#1162).

This change updates our code to also use upper case codes, and bumps the
minimum version of pyproj to ensure that we're always using a version
which also uses the upper case codes.
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 this pull request may close these issues.

None yet

1 participant