Database autoupdates #33

Closed
opened 2026-09-27 12:00:01 -07:00 by girlnamedzero · 0 comments
Owner

If the local database is >= x days old, set by an environment variable, but defaulting to 7 days, cldr should ask the user if they'd like to update it.

Additionally, when the user manually downloads/updates a database (maybe different for each language), ask the user if they want to update it automatically. Maybe migrate the updated_on file to a shared 'general' db file, something like meta-info, which has lines for the last update, whether it should be autoupdated, and any other information from later updates.

Implementation would then proceed as follows:
Try to print the queried page.
Path 1: The page was found, print the page. Then check if the age is over the set value. If it is, check if it should be auto updated, if yes, run the update code.
Path 2: The page was not found. Check if the age is over the set value, then if it should be auto updated, then update it, THEN try to print the page again, if it still wasn't found, exit.
(Note, if plain text is specified, we should consider skipping autoupdates entirely)

If the local database is >= x days old, set by an environment variable, but defaulting to 7 days, cldr should ask the user if they'd like to update it. Additionally, when the user manually downloads/updates a database (maybe different for each language), ask the user if they want to update it automatically. Maybe migrate the updated_on file to a shared 'general' db file, something like meta-info, which has lines for the last update, whether it should be autoupdated, and any other information from later updates. Implementation would then proceed as follows: Try to print the queried page. Path 1: The page was found, print the page. Then check if the age is over the set value. If it is, check if it should be auto updated, if yes, run the update code. Path 2: The page was not found. Check if the age is over the set value, then if it should be auto updated, then update it, THEN try to print the page again, if it still wasn't found, exit. (Note, if plain text is specified, we should consider skipping autoupdates entirely)
girlnamedzero 2026-09-28 14:05:21 -07:00
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
girlnamedzero/cldr#33
No description provided.