Skip to content

Fix task side effects after direct file edits#1925

Open
martin-forge wants to merge 1 commit into
callumalpass:mainfrom
martin-forge:martin-forge/issue-1921-external-calendar-reconciliation-standalone
Open

Fix task side effects after direct file edits#1925
martin-forge wants to merge 1 commit into
callumalpass:mainfrom
martin-forge:martin-forge/issue-1921-external-calendar-reconciliation-standalone

Conversation

@martin-forge
Copy link
Copy Markdown
Contributor

@martin-forge martin-forge commented May 22, 2026

Summary

Fixes #1921.

  • Registers reconciliation on TaskNotes' existing file-updated emitter after lazy calendar service initialization.
  • Persists calendar-relevant task fingerprints in plugin data so external markdown/frontmatter edits can be compared to the last synced state.
  • Routes changed linked tasks through existing Google Calendar update behavior, and creates eligible unlinked tasks when create-on-sync is enabled.
  • Reconciles external status transitions with the existing auto-archive service by scheduling or cancelling queued auto-archives from the current status config.
  • Baselines missing startup fingerprints without Google Calendar API writes or auto-archive scheduling to avoid first-run bulk side effects.

Related to #1696 and #1924. This PR is intentionally scoped to direct task-file reconciliation; moved-recurring exception support is separate.

Tests

  • npm test -- --runInBand tests/services/TaskCalendarSyncService.test.ts tests/unit/issues/issue-google-calendar-external-file-reconciliation.test.ts
  • npm run typecheck
  • npm run lint
  • npm run build
  • vault-python 7 System/Scripts/vault/scan_public_pr.py --repo /Users/martin/Developer/tasknotes-main --base origin/main --head martin-forge/issue-1921-external-calendar-reconciliation-standalone

@martin-forge martin-forge marked this pull request as ready for review May 22, 2026 03:10
@martin-forge martin-forge force-pushed the martin-forge/issue-1921-external-calendar-reconciliation-standalone branch from b5d527a to f27af5c Compare May 22, 2026 03:23
@martin-forge martin-forge changed the title Reconcile Google Calendar sync after direct task file edits Reconcile task side effects after direct task file edits May 22, 2026
@martin-forge martin-forge changed the title Reconcile task side effects after direct task file edits Fix task side effects after direct file edits May 22, 2026
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.

[Bug]: Direct frontmatter task completion does not trigger Google Calendar or auto-archive side effects

1 participant