Skip to content

fix(taskctl): retry and override commands fail — pipeline field immutability guard not bypassed #265

@randomm

Description

@randomm

Task Description

taskctl retry <taskId> and taskctl override <taskId> both fail with:

Cannot update immutable fields: pipeline. Use specialized methods for comments and pipeline events.

Root Cause

store.ts added an immutability guard for the pipeline field (IMMUTABLE_FIELDS array). pulse.ts correctly passes allowImmutable = true as the third argument to Store.updateTask. But the retry and override command handlers in tool.ts call Store.updateTask without this flag, so they hit the guard.

Fix

In tool.ts, for both retry (line 925) and override commands, pass true as the third argument to Store.updateTask:

await Store.updateTask(projectId, params.taskId, { ... }, true)

Quality Gates (Non-Negotiable)

  • TDD: Write tests before implementation
  • Coverage: 80%+ test coverage for new code
  • Linting: All code passes project linting rules
  • Local Verification: All tests pass locally before completion

Acceptance Criteria

  • taskctl retry <taskId> successfully resets a stuck task to open
  • taskctl override <taskId> --skip and --commit-as-is work without error
  • Tests verify both commands succeed on a task in adversarial-running stage

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions