feat: record slide subagent generation state#31
Conversation
|
Quick pass done locally.
No obvious blockers from this pass. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 865441114d
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| for value in (jobs.get("selected_backend"), prompt_job.get("expected_backend")): | ||
| if isinstance(value, str) and value.strip(): | ||
| labels.append(value.strip()) | ||
| labels.extend(_method_backend_labels(jobs.get("sample_generation_method"))) | ||
| labels.extend(_method_backend_labels(prompt_job.get("sample_generation_method"))) |
There was a problem hiding this comment.
Enforce a single expected backend when recording results
record_slide_result.py accepts a worker result if --backend-used matches any label gathered from selected_backend, prompt expected_backend, and sample_generation_method fields. When those fields are inconsistent (for example selected_backend="built-in image tool" but sample method labels scripts/image_gen.py), a worker can switch backend and still be recorded as successful, which breaks the new “fixed backend after sample approval” contract and can silently mix generation paths within one deck.
Useful? React with 👍 / 👎.
| slide["status"] = "dispatched" | ||
| update_jobs_run_status(jobs) |
There was a problem hiding this comment.
Block dispatch when max concurrent slides is already reached
record_slide_dispatch.py transitions a slide from pending to dispatched without checking current active dispatch count against max_concurrent_slides. This allows the state file to record more active jobs than the configured cap, so orchestration that relies on these scripts can oversubscribe subagents/resources and violate the intended concurrency limit.
Useful? React with 👍 / 👎.
Summary
Verification