Skip to content

web: request the plan for a draft without creationExecutions - #10

Merged
reoring merged 1 commit into
mainfrom
fix/plan-kickoff-missing-executions
Nov 12, 2026
Merged

reoring merged 1 commit into
mainfrom
fix/plan-kickoff-missing-executions

Conversation

@reoring

@reoring reoring commented Nov 12, 2026

Copy link
Copy Markdown
Contributor

Problem

On Craftsman (v0.5.3) every new AI draft shows 「計画を作れませんでした」 and retrying does not help. generate() reads current.creationExecutions.length, but the Platform API omits an empty creationExecutions (omitempty), so a never-executed draft throws a TypeError before createGeneration is called. Introduced by #4.

Change

  • Read the array with optional chaining, like the other four readers in the file.
  • Regression test with the draft shape the API actually returns (no creationExecutions); it fails without the fix.

Evidence

Craftsman pj-a167a047c8d3, read-only: 0 stored plan generations for the 8 drafts handed off since 2026-11-10; the 9 never-executed stored drafts all throw on this expression.

Tracker: APT-748, APT-749

Checks

  • bun test src/features/build/use-build-session.test.tsx: 37 pass (new test fails on main)
  • tsc --noEmit: clean

The Platform API omits an empty creationExecutions array. generate() read
its length unguarded, so every never-executed draft threw before the plan
generation request and showed 計画を作れませんでした (APT-748, APT-749).
@reoring
reoring merged commit 503434d into main Nov 12, 2026
3 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.

1 participant