Automatic check_date:opening_hours on change and subkeys in check() methods#1024
Open
CeleryCrusher wants to merge 3 commits intoZverik:mainfrom
Open
Automatic check_date:opening_hours on change and subkeys in check() methods#1024CeleryCrusher wants to merge 3 commits intoZverik:mainfrom
check_date:opening_hours on change and subkeys in check() methods#1024CeleryCrusher wants to merge 3 commits intoZverik:mainfrom
Conversation
check_date:opening_hours on change and generalize check() methodcheck_date:opening_hours on change and subkeys in check() methods
Zverik
requested changes
Feb 20, 2026
Owner
|
Hi CeleryCrusher, thanks for the pull request! I guess I'm okay with adding this change, but please fix a couple technical imperfections I've noticed. |
Author
|
I saw in the contributors guide to:
So here is my comment. I fixed the issues you mentioned. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes: #966
This PR generalizes the
check(),uncheck(), andtogglecheck()methods inOsmChangeto allow optional sub-keys and uses this to automatically addcheck_date:opening_hours=<Current Date>when the user has edited the opening hours and delete the key when the opening hours are deleted.I encountered the issue of having to manually add or remove this tag every time I changed the opening hours while surveying today so automatically handling this greatly reduces friction.
This tag greatly helps the maintainability and the usability of POI data and, as mentioned in issue #966, is already automatically added in StreetComplete and used in CoMaps, so real world use is evident.
Tested on Android 16 in Android Studio.
checkdate_demo.mp4
This is my first, although simple, PR, so please tell me if something needs to be improved.