Skip to content

Update CRS definitions; add geometamaker.load - #146

Merged
phargogh merged 16 commits into
natcap:mainfrom
davemfish:feature/88-crs-definitions
Jul 28, 2026
Merged

phargogh merged 16 commits into
natcap:mainfrom
davemfish:feature/88-crs-definitions

Conversation

@davemfish

@davemfish davemfish commented Jul 21, 2026 •

Copy link
Copy Markdown
Collaborator

This PR refactors how projections are represented in order to handle cases where a projection does not have an EPSG code. In those cases, the Well-Known-Text representation is stored instead. While we could always opt for WKT, the brevity of the EPSG code seems desirable in the context of these documents. Authorities other than EPSG (e.g. ESRI) are uncommon and so rather than handling all possible authorities, I opted to fall back to WKT for those.

Existing metadata documents with the old data model will be automatically migrated to the new during describe.

I also added a geometamaker.load function as discussed in #111 . load does not support migrating schema because it is safest to re-describe the original dataset to be sure that the CRS and other attributes are still accurate.

Fixes #88
Fixes #111

@davemfish davemfish changed the title Feature/88 crs definitions Updat CRS definitions Jul 21, 2026
@davemfish davemfish changed the title Updat CRS definitions Update CRS definitions; add geometamaker.load Jul 23, 2026
@davemfish
davemfish marked this pull request as ready for review July 23, 2026 13:59
@davemfish
davemfish requested a review from phargogh July 28, 2026 13:54

@phargogh phargogh left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks @davemfish ! I don't have any suggestions or comments on this PR. In addition to the CRS definitions, this is the first time I'm encountering migrations in geometamaker, so that's exciting to see!

@phargogh
phargogh merged commit 800ed46 into natcap:main Jul 28, 2026
61 checks passed
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.

Add a feature to instantiate a Resource from a YML doc warnings about valid coordinate systems

2 participants