Format supersession follow-up changes
This commit is contained in:
@@ -35,10 +35,12 @@ vi.mock('./config.js', () => ({
|
|||||||
vi.mock('./paired-execution-context.js', () => ({
|
vi.mock('./paired-execution-context.js', () => ({
|
||||||
preparePairedExecutionContext: vi.fn(() => undefined),
|
preparePairedExecutionContext: vi.fn(() => undefined),
|
||||||
completePairedExecutionContext: vi.fn(),
|
completePairedExecutionContext: vi.fn(),
|
||||||
resolveOwnerTaskForHumanMessage: vi.fn((args?: { existingTask?: unknown }) => ({
|
resolveOwnerTaskForHumanMessage: vi.fn(
|
||||||
task: args?.existingTask ?? null,
|
(args?: { existingTask?: unknown }) => ({
|
||||||
supersededTask: null,
|
task: args?.existingTask ?? null,
|
||||||
})),
|
supersededTask: null,
|
||||||
|
}),
|
||||||
|
),
|
||||||
}));
|
}));
|
||||||
|
|
||||||
vi.mock('./db.js', () => {
|
vi.mock('./db.js', () => {
|
||||||
|
|||||||
@@ -173,7 +173,8 @@ function cancelOutstandingFinalizeOwnerTurn(task: PairedTask): void {
|
|||||||
}
|
}
|
||||||
cancelPairedTurn({
|
cancelPairedTurn({
|
||||||
turnIdentity,
|
turnIdentity,
|
||||||
error: 'Superseded by a newer human message before owner finalize delivery.',
|
error:
|
||||||
|
'Superseded by a newer human message before owner finalize delivery.',
|
||||||
});
|
});
|
||||||
logger.info(
|
logger.info(
|
||||||
{
|
{
|
||||||
@@ -358,8 +359,7 @@ export function preparePairedExecutionContext(args: {
|
|||||||
// bot-only ping-pong must accumulate the counter for loop detection.
|
// bot-only ping-pong must accumulate the counter for loop detection.
|
||||||
const hasHuman = args.hasHumanMessage === true;
|
const hasHuman = args.hasHumanMessage === true;
|
||||||
const needsStatusReset =
|
const needsStatusReset =
|
||||||
latestTask.status === 'review_ready' ||
|
latestTask.status === 'review_ready' || latestTask.status === 'in_review';
|
||||||
latestTask.status === 'in_review';
|
|
||||||
if (hasHuman || needsStatusReset) {
|
if (hasHuman || needsStatusReset) {
|
||||||
if (needsStatusReset) {
|
if (needsStatusReset) {
|
||||||
transitionPairedTaskStatus({
|
transitionPairedTaskStatus({
|
||||||
|
|||||||
Reference in New Issue
Block a user