Skip to content

fix: re-read frontmatter before modal save to prevent overwriting concurrent task edits - #2291

Open
martin-forge wants to merge 2 commits into
callumalpass:mainfrom
martin-forge:martin-forge/fix-modal-concurrent-task-edits
Open

fix: re-read frontmatter before modal save to prevent overwriting concurrent task edits#2291
martin-forge wants to merge 2 commits into
callumalpass:mainfrom
martin-forge:martin-forge/fix-modal-concurrent-task-edits

Conversation

@martin-forge

@martin-forge martin-forge commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Problem

A background update to a task file can be undone when an already-open task edit window saves an unrelated change. For example, changing an estimate can restore an old scheduled date after a recurring task was completed elsewhere.

Solution

Read the latest frontmatter inside Obsidian's save callback and apply only the requested fields. Preserve background edits, completed occurrences and fields another writer removed. This changes the task update service only; it does not depend on the Calendar or security proposals.

Testing

  • 110 focused tests pass, including a stale-edit regression and existing task/recurrence tests.
  • npm run lint and npm run build:test pass.
  • Reloaded the standalone build in a disposable Obsidian vault; no captured errors.
  • GitHub CI: full test suite and build passed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant