1.8 KiB
D01 — Development queue predicate mismatch
Date: 16 November 2026. Target independently verified as PlotDirector_Development. Verification: Both verified, with live read-only database definition inspection.
Application WriterWorkspaceService.GetDashboardAsync calls the repository with:
WriteNext
ContinueWriting
RevisionQueue
PolishingQueue
PlotLine/Sql/052_RevisionStatusWriterWorkflow.sql maps these to canonical scene statuses:
WriteNext -> Outlined
ContinueWriting -> Drafted
RevisionQueue -> Needs Work
PolishingQueue -> Revised
The actual live dbo.WriterDashboard_Scenes definition read from sys.sql_modules instead ended with these recognised queue predicates:
WHERE (@Queue = N'Blocked' AND sb.IsBlocked = 1)
OR (@Queue = N'ReadyForDraft' AND sb.ReadyForDraft = 1)
OR (@Queue = N'ReadyForRevision' AND sb.ReadyForRevision = 1)
OR (@Queue = N'ReadyForPolish' AND sb.ReadyForPolish = 1)
OR (@Queue = N'Warnings' AND ISNULL(warnings.WarningCount, 0) > 0)
A direct read-only execution with the fixture project and @Queue=N'WriteNext' returned no rows. A separate joined SELECT confirmed four active fixture scene records with statuses Outlined, Drafted, Needs Work and Revised, all in the fixture's chapter/book/project. Authenticated browser navigation to all four queue tabs showed zero counts and the generic Revision Status instructions. Story Health still showed its missing-goal reminder. The mismatch explains this fixture outcome without changing the database.
This is evidence of live/source contract drift, not proof of which historical deployment caused it. The audit does not prescribe replaying migration052: existing migrations remain immutable and repair/deployment requires a separate implementation task. No SQL/schema repair was applied.