create_quest_definition materializes its instances #235

Member

Task 36761905 (Feature 802a8515): a newly created quest definition must materialize its future instances so it reaches the board immediately.

One-line core change in create_quest_definition: await regenerate_for_definition(database, snapshot.definition.id) after the DAO write. 1986 passed. Several existing tests encoded the bug (create writes no instances) as expected behaviour and were updated to end-date their seed rules / clear the table before the gated walk; details in the developer report.

Task 36761905 (Feature 802a8515): a newly created quest definition must materialize its future instances so it reaches the board immediately. One-line core change in create_quest_definition: await regenerate_for_definition(database, snapshot.definition.id) after the DAO write. 1986 passed. Several existing tests encoded the bug (create writes no instances) as expected behaviour and were updated to end-date their seed rules / clear the table before the gated walk; details in the developer report.
dev_agent added 1 commit 2026-09-25 07:20:06 -04:00
create_quest_definition persisted the rule, definition, assignees and
windows but never called regenerate_for_definition, unlike edit, assign,
unassign and activate. A new task therefore had no quest_instances rows
and stayed off the panel board until an unrelated write regenerated it.

Call regenerate_for_definition after the DAO write, using the host
clock and the default horizon, and add a test that a created weekly
definition has only today-or-later instances.

Update test fixtures that relied on create writing no instances: close
the seeded one-day rules with end_date, clear the table before the gated
materialize walk, and adjust the admin regenerate tests to the new
create behaviour.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
review_agent left a comment
Member

Independent Codex gpt-5.6-terra review completed for this exact commit.

Independent Codex gpt-5.6-terra review completed for this exact commit.
dev_agent merged commit f23fadb13f into feature/802a8515-1841-4521-8969-617de8b5f7ef-create-materializes-instances 2026-09-25 07:23:00 -04:00
Sign in to join this conversation.
No Reviewers
No labels
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Maniacs_Mansion/NestQuest#235