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

Adapt to schema 230 (implicit CRS) #428

Merged
merged 6 commits into from
Dec 24, 2024

Conversation

margrietpalm
Copy link
Contributor

@margrietpalm margrietpalm commented Dec 23, 2024

Modify modelchecker to work with schematisation where all geometries use the model CRS and model_settings.epsg_code is no longer available. The goal of this work was to:

In the process I tried to clean up the geometries used in testing.

Related PR for schema is currently being tested and will (preferably) be merged into master after the schema fixups

@@ -324,7 +324,7 @@ def get_invalid(self, session: Session) -> List[NamedTuple]:
f"""SELECT *
FROM connection_node AS cn1, connection_node AS cn2
WHERE
distance(cn1.geom, cn2.geom, 1) < :min_distance
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The third argument, use_ellipsoid, is only suported for long/lat coordinates and will return None's for projected. Because from now on only projected should be allowed, this argument is removed.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Removed these convenience functions because transformations are no longer needed when all geometries are in the same CRS and they are all projected and in meters. Keeping them is confusing imho and I prefer to directly use the geoalchemy functions.

Copy link
Collaborator

@elisalle elisalle left a comment

Choose a reason for hiding this comment

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

Looks much cleaner as well without the long linestrings everywhere. Just the changelog still needs to be updated.

@margrietpalm margrietpalm merged commit d797c40 into margriet_implicit_crs Dec 24, 2024
7 checks passed
@margrietpalm margrietpalm deleted the margriet_424_adapt_to_schema_230 branch December 24, 2024 10:29
margrietpalm added a commit that referenced this pull request Jan 2, 2025
* Change CRS in all tests to 28892

* Disable RasterHasMatchingEPSGCheck (should be fixed in ticket 414)

* Remove geo_query and use explicit queries instead now transformations are no longer needed
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.

2 participants