Skip to content

fix: sync fableLoom RESTORABLE_FIELDS with the actual restorable field set - #6100

Merged
atomantic merged 1 commit into
atomantic:mainfrom
Bryandero98:fix/restorable-fields-fableloom-parity
Sep 3, 2026
Merged

fix: sync fableLoom RESTORABLE_FIELDS with the actual restorable field set#6100
atomantic merged 1 commit into
atomantic:mainfrom
Bryandero98:fix/restorable-fields-fableloom-parity

Conversation

@Bryandero98

Copy link
Copy Markdown
Contributor

Summary

  • Fixes Conflict journal RESTORABLE_FIELDS parity drift for FableLoom drops protagonist and production approvals on restore #6010
  • server/lib/conflictJournal.js's RESTORABLE_FIELDS.fableLoom — documented as the single source of truth for conflict restore/merge — was missing productionStatus, protagonistCharacterId, protagonistWardrobeId, and protagonistWardrobeLocked, even though server/services/fableLoom/records.js already treats them as restorable.
  • Real impact: restoring a conflict via "Restore All" silently stripped those 4 fields, and "merge fields" rejected them outright with ERR_VALIDATION — data loss for protagonist continuity and production sign-off after a sync conflict (see the issue's trigger scenario for the full repro).
  • Added the 4 fields to RESTORABLE_FIELDS.fableLoom to close the gap.

Test plan

  • Added restore-all/merge-fields coverage in conflictJournalResolver.test.js for all 4 fields, split into separate cases so the protagonist-fields restore and the productionStatus restore don't collide with mutateLoom's own (unrelated, intentional) rule that clears productionStatus whenever editorial content actually changes.
  • cd server && npx vitest run services/conflictJournalResolver.test.js lib/conflictJournal.test.js → 60/60 passed.

🤖 Generated with Claude Code

…d set (atomantic#6010)

server/lib/conflictJournal.js's RESTORABLE_FIELDS.fableLoom (documented
as the single source of truth for conflict restore/merge) was missing
productionStatus, protagonistCharacterId, protagonistWardrobeId, and
protagonistWardrobeLocked, even though records.js already treats them
as restorable. Concretely: restoring a conflict via "Restore All"
silently stripped those 4 fields, and "merge fields" rejected them
outright with ERR_VALIDATION — a real data-loss path for protagonist
continuity and production sign-off after a sync conflict.

Added the 4 fields to close the gap. Added restore-all and
merge-fields coverage in conflictJournalResolver.test.js, split so the
protagonist-fields case and the productionStatus case don't collide
with mutateLoom's own (unrelated, intentional) rule that clears
productionStatus whenever editorial content actually changes.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@atomantic
atomantic merged commit 545bfa3 into atomantic:main Sep 3, 2026
7 checks 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.

Conflict journal RESTORABLE_FIELDS parity drift for FableLoom drops protagonist and production approvals on restore

2 participants