Repository navigation
docs(#161): fix the template_todo_alarm examples - #183
Open
VanshajPoonia wants to merge 1 commit into
Open
VanshajPoonia wants to merge 1 commit into
VanshajPoonia wants to merge 1 commit into
Conversation
template_todo_alarm is parsed with the user's Joplin date and time format, so the examples passing format="YYYY-MM-DD HH:mm" failed for anyone using a different format. The usage example also put double quotes inside a helper argument, which breaks frontmatter parsing on the released version (joplin#177). Drop the custom format, use single quotes for set_time, and correct the note that said the variable expects "YYYY-MM-DD HH:mm".
VanshajPoonia
marked this pull request as ready for review
October 12, 2026 17:13
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 #161
What
format="YYYY-MM-DD HH:mm"from the twotemplate_todo_alarmexamples.set_timein the usage example.template_todo_alarmexpects "YYYY-MM-DD HH:mm".Why
template_todo_alarmis parsed strictly with the user's Joplin date and time format (getNoteMetadatapassesgetDateTimeFormat()toformatLocalToJoplinCompatibleUnixTime). A hardcodedYYYY-MM-DD HH:mmtherefore fails for anyone with a different format, for example "Was not able to parse 2021-08-15 09:00 according to format DD/MM/YYYY HH:mm". Thedatetimehelper already outputs the right format by default.The usage example also ran into #177: double quotes inside a helper argument stop the value from being auto-quoted, so the frontmatter failed to parse even with a
YYYY-MM-DDdate format. Single quotes avoid that on the released version. Once #177 is fixed, either style works.Testing
Parsed both examples directly from the README with the date format set to
DD/MM/YYYYand toYYYY-MM-DD. On master the old examples fail with both formats. The new ones pass with both, with and without the #177 fix.Also checked in a Joplin desktop dev build from the current
devbranch: the corrected usage example creates the to-do with its alarm three days ahead at 09:00, on master and with the #177 fix. The old example fails on master because of #177, and with the #177 fix it fails withWas not able to parse 2026-10-15 09:00 according to format DD/MM/YYYY HH:mm.AI Assistance Disclosure
I used an AI coding assistant to investigate the issue, write the change, and draft this description. The examples were checked locally and in a Joplin desktop dev build.