fix(report): accept section: job progress phases on read-back
Heartbeat and GET were parsing progress_phase with a pattern that rejects the colon prefix the writer already persists, which aborted generation after the first chapter. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -479,6 +479,23 @@ test("claim and heartbeat require the exact live lease token", async () => {
|
||||
});
|
||||
assert.equal(progressed.progressPhase, "building_evidence");
|
||||
assert.equal(progressed.progressPercent, 40);
|
||||
|
||||
const sectionProgress = await service.updateProgress({
|
||||
jobId: claimed.id,
|
||||
leaseToken: claimed.leaseToken,
|
||||
phase: "section:theme-health_pressure",
|
||||
percent: 52,
|
||||
});
|
||||
assert.equal(sectionProgress.progressPhase, "section:theme-health_pressure");
|
||||
backend.now = new Date("2026-08-14T03:00:20.000Z");
|
||||
const afterSection = await service.heartbeatLease({
|
||||
jobId: claimed.id,
|
||||
leaseToken: claimed.leaseToken,
|
||||
leaseSeconds: 60,
|
||||
});
|
||||
assert.equal(afterSection.progressPhase, "section:theme-health_pressure");
|
||||
const owned = await service.getOwnedByRequestId(USER_A, REQUEST_A);
|
||||
assert.equal(owned?.progressPhase, "section:theme-health_pressure");
|
||||
});
|
||||
|
||||
test("atomic completion binds the canonical v2 document to the exact live lease", async () => {
|
||||
|
||||
Reference in New Issue
Block a user