-
-
Notifications
You must be signed in to change notification settings - Fork 3.3k
Aligning with OSM usage policies #5122
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
base: main
Are you sure you want to change the base?
Conversation
Added 24 hours cache on Nominatim requests Added rate limiting on Nominatim requests Added OpenStreetMap attribution on leaflet map
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR implements OpenStreetMap (OSM) Nominatim usage policy compliance by adding rate limiting, caching, and attribution requirements for geocoding requests.
- Adds rate limiting with 1.3-second intervals between Nominatim API calls
- Implements caching headers for API requests to reduce server load
- Adds required OSM attribution to map components
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| LocationSelector.tsx | Implements rate limiting and caching for Nominatim reverse geocoding requests |
| LeafletMap.tsx | Adds OpenStreetMap attribution to comply with usage policies |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
web/src/components/MemoEditor/ActionButton/LocationSelector.tsx
Outdated
Show resolved
Hide resolved
web/src/components/MemoEditor/ActionButton/LocationSelector.tsx
Outdated
Show resolved
Hide resolved
web/src/components/MemoEditor/ActionButton/LocationSelector.tsx
Outdated
Show resolved
Hide resolved
Co-authored-by: Copilot <[email protected]> Signed-off-by: Johnny <[email protected]>
Signed-off-by: Tiny-Paws <[email protected]>
|
My linter didn't work properly due to git's core.autocrlf feature being enabled. Should pass static checks now |
Nominatim usage policy requires to use a rate limiter, cache and display attribution
This PR implements the above requirements.