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

Change MultiPoint WKT to use parentheses in sub-members #903

Merged
merged 4 commits into from
May 18, 2023

Conversation

mwtoews
Copy link
Contributor

@mwtoews mwtoews commented May 9, 2023

This is a potentially breaking change that switches the WKT output of MultiPoint from:

MULTIPOINT (2 8, 3 9)

to

MULTIPOINT ((2 8), (3 9))

This aligns with JTS' outputs of MultiPoint and with ISO/OGC specs.

See also postgis/postgis#682 which was implemented for PostGIS 3.3

@pramsey
Copy link
Member

pramsey commented May 9, 2023

I wonder how many downstream projects have tests against the WKT output of MULTIPOINT.

@mwtoews
Copy link
Contributor Author

mwtoews commented May 9, 2023

Possibly a few, for instance I'll try shapely later. Another strategy is to modify WKTWriter to enable an option, keeping the default to use old behaviour.

@dr-jts
Copy link
Contributor

dr-jts commented May 10, 2023

I wonder how many downstream projects have tests against the WKT output of MULTIPOINT.

I think we have to note this as a breaking change and move on. It's more important to be standards-compliant.

@dr-jts
Copy link
Contributor

dr-jts commented May 10, 2023

WKTReader can still handle both forms, right?

It's good to update the unit tests that aren't specifically checking this behaviour. But are there still tests for WKTReader that check both formats?

@mwtoews
Copy link
Contributor Author

mwtoews commented May 10, 2023

WKTReader can still handle both forms, right?

Yes, and I intentionally left a few test cases with the previous form. The only exception that I'm aware of #902 which will be closed as "not planned".

@mwtoews mwtoews merged commit 3b50997 into libgeos:main May 18, 2023
@mwtoews mwtoews deleted the multipoint-parens branch May 18, 2023 00:50
ejn pushed a commit to dvzgeo/php-geos that referenced this pull request Mar 14, 2024
ejn pushed a commit to dvzgeo/php-geos that referenced this pull request Mar 14, 2024
Also see libgeos/geos#903

Convert to consistent format before comparison, see: libgeos/geos@4acb5e0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants