Skip to content

Clear completed deletes from Busy using exact message identity - #35

Merged
mrinc merged 1 commit into
masterfrom
fix/reconcile-deleted-mail
Oct 4, 2026
Merged

mrinc merged 1 commit into
masterfrom
fix/reconcile-deleted-mail

Conversation

@bcbetterninja

Copy link
Copy Markdown
Collaborator

An Outlook message already moved to Deleted Items could remain in Busy after its stored server ID stopped resolving. Recovery searched by subject with a 100-result limit, while older delete actions stored deleteditems as their destination and compared it directly with Microsoft's opaque folder ID.

Microsoft recovery now uses an exact mailbox-wide internetMessageId filter, follows continuation pages to establish uniqueness, refetches the matched message, and resolves well-known destinations to their real folder IDs. A verified message already in the intended destination clears the pending action without another move request. A verified message elsewhere repairs the queued ID and authorizes one retry. Folder discovery also identifies Deleted Items, Archive and Junk aliases for future actions.

Persist a recovery version so older failed recoveries get one attempt with the improved lookup. The claim survives restart; successful previous repairs do not trigger repeated automatic recovery. Missing, ambiguous, incomplete or changed identities remain pending. This change handles messages in Deleted Items; it does not infer permanent deletion from a missing search result.

Validation:

  • Solution build: zero warnings/errors.
  • All 579 tests passed.
  • Twelve new regression cases use the real Microsoft provider, HTTP fixtures, encrypted store, provider router and Busy processor. They cover primary/shared mailboxes, fresh/legacy paused deletes, changed subjects and IDs, paginated ambiguity, repeated continuation links, refetch identity changes, folder aliases, missing destination reporting, and persisted recovery claims. Completed deletes issue only GET requests.

@coderabbitai

coderabbitai Bot commented Oct 3, 2026

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 3dc0891e-7e51-4bcc-9791-e07b726cd6fc
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@mrinc
mrinc merged commit 20fb5a4 into master Oct 4, 2026
8 of 9 checks passed
@mrinc
mrinc deleted the fix/reconcile-deleted-mail branch October 4, 2026 15:24
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.

2 participants