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

Prevent impossible & problematic coordinates from being entered in the editor #2216

Merged
merged 5 commits into from
Nov 2, 2023

Conversation

robyngit
Copy link
Member

@robyngit robyngit commented Nov 2, 2023

Add validation rules to the EmlGeoCoverage model to prevent:

  • North and South coordinates from being reversed (N must be > S)
  • Bounding boxes containing either the North or South pole
  • Bounding boxes crossing the anti-meridian

Show error messages in the editor when values described above are entered. Add tests for the EmlGeoCoverage model.

Also fix the HTML input regex pattern for coordinate fields.

- Show validation error when N coord is less than S coord
- Fix the HTML input pattern for decimal degrees (was throwing an error)
- Add a test for reversed coords to the EMLGeoCoverage model spec

Issue #2159
- Add validation rule to prevent bounding boxes from: containing the poles or crossing the anti-meridian
- Add unit tests for the new validation rules

Issue #2159
@robyngit robyngit added this to the 2.27.0 milestone Nov 2, 2023
@robyngit robyngit merged commit e0633ff into develop Nov 2, 2023
2 checks passed
@robyngit robyngit deleted the feature-2159-coord-validation branch September 26, 2024 17:24
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.

Prevent users from entering impossible geographic coordinates in the editor
1 participant