Skip to content

feat(undo): preserve operation records and add debug metadata#437

Merged
henrikje merged 1 commit intomainfrom
additional-debug-information-for-operations
Mar 26, 2026
Merged

feat(undo): preserve operation records and add debug metadata#437
henrikje merged 1 commit intomainfrom
additional-debug-information-for-operations

Conversation

@henrikje
Copy link
Copy Markdown
Owner

Stop deleting operation records after completion/undo/abort. Instead,
finalizeOperationRecord() marks them with completedAt, outcome, and
status: "completed". Records persist in .arbws/operation.json until
the next operation overwrites them, preserving diagnostic information.

Three additions:

  • Finalize instead of delete: new completedAt timestamp and outcome
    field ("completed", "aborted", "undone", "force-cleared") on the
    operation record. Only --force still deletes (corrupt records).
  • Capture git stderr on failure: truncated to 4000 chars in the
    per-repo errorOutput field for post-mortem debugging.
  • GIT_REFLOG_ACTION: set during execution loops so git reflog entries
    are tagged with arb-rebase, arb-undo, etc.
  • Include operation record in arb dump per-workspace output.

Co-Authored-By: Claude Opus 4.6 (1M context) noreply@anthropic.com

Stop deleting operation records after completion/undo/abort. Instead,
finalizeOperationRecord() marks them with completedAt, outcome, and
status: "completed". Records persist in .arbws/operation.json until
the next operation overwrites them, preserving diagnostic information.

Three additions:
- Finalize instead of delete: new completedAt timestamp and outcome
  field ("completed", "aborted", "undone", "force-cleared") on the
  operation record. Only --force still deletes (corrupt records).
- Capture git stderr on failure: truncated to 4000 chars in the
  per-repo errorOutput field for post-mortem debugging.
- GIT_REFLOG_ACTION: set during execution loops so git reflog entries
  are tagged with arb-rebase, arb-undo, etc.
- Include operation record in arb dump per-workspace output.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@henrikje henrikje enabled auto-merge (rebase) March 26, 2026 09:48
@henrikje henrikje merged commit 2417d65 into main Mar 26, 2026
10 checks passed
@henrikje henrikje deleted the additional-debug-information-for-operations branch March 26, 2026 09:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant