Skip to content

Commit f28a687

Browse files
clawplaysclaude
andcommitted
Release 1.9.3
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
1 parent 154a4c0 commit f28a687

11 files changed

Lines changed: 71 additions & 13 deletions

dist/cli.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ const VerifyCommand_1 = require("./commands/VerifyCommand");
6262
const WorkflowCommand_1 = require("./commands/WorkflowCommand");
6363
const LayoutCommand_1 = require("./commands/LayoutCommand");
6464
const services_1 = require("./services");
65-
const CLI_VERSION = '1.9.2';
65+
const CLI_VERSION = '1.9.3';
6666
function showInitUsage() {
6767
console.log('Usage: ospec init [root-dir] [--summary "..."] [--tech-stack node,react] [--architecture "..."] [--document-language en-US|zh-CN|ja-JP|ar]');
6868
}

dist/services/LoopService.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1336,6 +1336,9 @@ class LoopService {
13361336
feedback = deterministicAcceptance.reason;
13371337
state.lastFeedback = feedback;
13381338
}
1339+
else {
1340+
await this.taskGraph.closeOutSupersededPlanningRepair(resolved);
1341+
}
13391342
const allowedWorkspacePaths = this.allReportTasks(report)
13401343
.filter(task => task.status !== 'PENDING')
13411344
.flatMap(task => task.targetFiles);

dist/services/TaskGraphExecutionService.d.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1591,6 +1591,14 @@ export declare class TaskGraphExecutionService {
15911591
accepted: boolean;
15921592
reason: string;
15931593
}>;
1594+
/**
1595+
* A dispatched grouped repair whose completion evidence never settled leaves
1596+
* its record in 'dispatched' with planning edits already applied. When a later
1597+
* combined planning review approves that content, accept the repair as done:
1598+
* otherwise a later planning cycle misreads the record as a partial edit and
1599+
* dead-ends the Goal even though its planning was approved.
1600+
*/
1601+
closeOutSupersededPlanningRepair(changePath: string): Promise<boolean>;
15941602
private buildPostRepairReviewSections;
15951603
private buildPlanningRepairDiffSections;
15961604
private buildVerificationFailureFocusSections;

dist/services/TaskGraphExecutionService.js

Lines changed: 41 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3284,6 +3284,36 @@ class TaskGraphExecutionService {
32843284
};
32853285
});
32863286
}
3287+
/**
3288+
* A dispatched grouped repair whose completion evidence never settled leaves
3289+
* its record in 'dispatched' with planning edits already applied. When a later
3290+
* combined planning review approves that content, accept the repair as done:
3291+
* otherwise a later planning cycle misreads the record as a partial edit and
3292+
* dead-ends the Goal even though its planning was approved.
3293+
*/
3294+
async closeOutSupersededPlanningRepair(changePath) {
3295+
return this.withTaskGraphMutationLease(changePath, async () => {
3296+
const resolvedChangePath = path.resolve(changePath);
3297+
const recordPath = path.join(resolvedChangePath, 'artifacts', 'agents', PLANNING_REPAIR_FILE);
3298+
if (!(await this.fileService.exists(recordPath)))
3299+
return false;
3300+
let record;
3301+
try {
3302+
record = await this.fileService.readJSON(recordPath);
3303+
}
3304+
catch {
3305+
return false;
3306+
}
3307+
if (record.status !== 'dispatched')
3308+
return false;
3309+
const context = await this.capturePlanningContext(resolvedChangePath);
3310+
record.status = 'completed';
3311+
record.completedAt = new Date().toISOString();
3312+
record.afterSnapshotHash = context.targetSnapshotHash;
3313+
await this.fileService.writeJSON(recordPath, record);
3314+
return true;
3315+
});
3316+
}
32873317
async buildPostRepairReviewSections(changePath, projectRoot) {
32883318
const recordPath = path.join(changePath, 'artifacts', 'agents', PLANNING_REPAIR_FILE);
32893319
if (!(await this.fileService.exists(recordPath)))
@@ -3295,7 +3325,11 @@ class TaskGraphExecutionService {
32953325
catch {
32963326
return [];
32973327
}
3298-
if (record.status !== 'completed' || record.postRepairReviewMode === 'deterministic')
3328+
// Include repair context for a dispatched-but-unsettled repair too: its
3329+
// edits are already in the planning files, and the fresh reviewer must
3330+
// know which findings that repair was resolving.
3331+
if ((record.status !== 'completed' && record.status !== 'dispatched')
3332+
|| record.postRepairReviewMode === 'deterministic')
32993333
return [];
33003334
return [
33013335
'',
@@ -8067,10 +8101,12 @@ class TaskGraphExecutionService {
80678101
}
80688102
}
80698103
if (normalizedPath.endsWith(`/${constants_1.FILE_NAMES.TASKS}`.toLowerCase()) || normalizedPath === constants_1.FILE_NAMES.TASKS.toLowerCase()) {
8070-
// tasks.md is derived from task graph state; checklist ticks are execution
8071-
// progress, not planning content.
8072-
const checklistNeutral = content.replace(/^(\s*[-*+]\s+\[)[xX](\])/gm, '$1 $2');
8073-
return this.hashMeaningfulDocumentation(checklistNeutral);
8104+
// tasks.md is fully derived from task graph state. Its churn — checklist
8105+
// ticks, repair-wave lines, closeout checklists — is execution progress,
8106+
// not planning content, so it contributes a constant to the snapshot and
8107+
// can never invalidate a planning approval. It remains a valid
8108+
// repair-scope target; semantic task changes surface via the task graph.
8109+
return (0, crypto_1.createHash)('sha256').update('ospec:planning:derived:tasks.md', 'utf8').digest('hex');
80748110
}
80758111
return this.hashMeaningfulDocumentation(content);
80768112
}

docs/usage.ar.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ ospec finalize [changes/active/<change>]
222222
```
223223

224224
```bash
225-
npm install -g @clawplays/ospec-cli@1.9.2
225+
npm install -g @clawplays/ospec-cli@1.9.3
226226
ospec update [path]
227227
```
228228

docs/usage.ja.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ AI harness が 1 つの active Goal を進め、ユーザー判断と runtime ev
222222
```
223223

224224
```bash
225-
npm install -g @clawplays/ospec-cli@1.9.2
225+
npm install -g @clawplays/ospec-cli@1.9.3
226226
ospec update [path]
227227
```
228228

docs/usage.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ Recommended prompt:
223223
```
224224

225225
```bash
226-
npm install -g @clawplays/ospec-cli@1.9.2
226+
npm install -g @clawplays/ospec-cli@1.9.3
227227
ospec update [path]
228228
```
229229

docs/usage.zh-CN.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ goal 以**会话内 task graph 循环**运行,并统一使用一条快速质
223223
```
224224

225225
```bash
226-
npm install -g @clawplays/ospec-cli@1.9.2
226+
npm install -g @clawplays/ospec-cli@1.9.3
227227
ospec update [path]
228228
```
229229

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@clawplays/ospec-cli",
3-
"version": "1.9.2",
3+
"version": "1.9.3",
44
"description": "Official OSpec CLI package for spec-driven development (SDD) and document-driven development in AI coding agent and CLI workflows.",
55
"main": "dist/index.js",
66
"types": "dist/index.d.ts",

0 commit comments

Comments
 (0)