SIGN IN SIGN UP

Fix slash-containing date formats and make periodic note periods always available (#313)

* Add failing tests for slash-containing periodic note date formats

Core Daily Notes supports date formats like YYYY/MM/YYYY-MM-DD, where the
formatted filename spans subfolders beneath the configured folder. The
native periodic-notes implementation introduced in #308 breaks for such
formats in both directions: create() only ensures the configured base
folder exists (so vault.create fails on the missing intermediate
folders, where the old obsidian-daily-notes-interface created them), and
getAll() strictly parses only the file's basename against the full
format (so existing notes are never found). These tests capture the
intended behavior ahead of the fix, per the TDD convention.

Also extends the Vault mock to record createFolder calls.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Support slash-containing date formats in periodic note resolution

Fixes the two failure modes captured by the previous commit: create()
now ensures the parent folder chain of the full computed note path (the
formatted filename may span subfolders), matching the behavior of the
obsidian-daily-notes-interface library this implementation replaced;
and getAll() matches a slash-containing format against the file's
folder-relative path instead of its basename, so such notes are found
by reads (something even the old library got wrong). Formats without a
slash keep the existing basename matching, including notes manually
nested under the configured folder.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Treat all periodic note periods as always enabled

The per-period Enable toggle introduced with the native periodic-notes
settings (#308) added a failure mode with no real upside: a request for
an unconfigured period returned 400 PeriodIsNotEnabled (40060), where
serving the period with sensible defaults (vault root, the period's
standard filename format, no template) costs nothing and just works.
Every period is now always available; the settings section configures
folder/format/template only, and the per-period display value shows the
effective location and format instead of an enabled state.

The seed-once migration still imports folder/format/template from the
core Daily Notes / community Periodic Notes plugins (and still only
from periods those plugins had enabled, since a disabled period's
config there may be stale); it just no longer carries an enabled flag.

Removes ErrorCode.PeriodIsNotEnabled and the PeriodicNoteInterface
'loaded' field, updates the MCP periodic_note_get_path description and
the OpenAPI/README docs to describe the always-available behavior and
where configuration lives, and drops the integration-test block for the
retired 40060 response.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
A
Adam Coddington committed
86ed823507a67b394bcd8a4302136c6e7f6eab42
Parent: 24014d3
Committed by GitHub <noreply@github.com> on 7/24/2026, 3:19:32 AM