@sagentlab/navarch-runtime 0.1.166 → 0.1.167
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/session.cjs +5 -1
- package/package.json +1 -1
package/dist/session.cjs
CHANGED
|
@@ -761,7 +761,11 @@ async function runClaimedSession(deps, claimed, sessionId, lifecycle) {
|
|
|
761
761
|
await gitWorktree.prepare();
|
|
762
762
|
// Capture once before agent work. The server returns the first baseline
|
|
763
763
|
// after a restart, so a retry cannot relabel inherited commits as output.
|
|
764
|
-
|
|
764
|
+
// Reviews may check out an unmerged PR after prepare(). The production
|
|
765
|
+
// base counts those inherited commits as new work. Read the server's
|
|
766
|
+
// claim-time PR pin even for claims without the required-baseline flag.
|
|
767
|
+
// A continuation with no persisted pin must fail, never capture a late head.
|
|
768
|
+
if (claimed.delivery_baseline_required || task.task_type === "review") {
|
|
765
769
|
const initialHead = await (0, delivery_cjs_1.captureDeliveryBaseline)(gitWorktree.worktreePath);
|
|
766
770
|
if (!/^[0-9a-f]{40}$/.test(initialHead))
|
|
767
771
|
throw new Error("Delivery baseline capture returned an invalid SHA");
|
package/package.json
CHANGED