Skip to content

Preserve local PR cleanup results#440

Merged
chubes4 merged 2 commits into
mainfrom
fix/pr-cleanup-partial-success
May 20, 2026
Merged

Preserve local PR cleanup results#440
chubes4 merged 2 commits into
mainfrom
fix/pr-cleanup-partial-success

Conversation

@chubes4
Copy link
Copy Markdown
Member

@chubes4 chubes4 commented May 20, 2026

Summary

  • Adds local_only support to merged PR cleanup so DMC can finalize/remove local worktrees without requiring remote branch deletion.
  • Preserves local DMC worktree cleanup evidence as a partial success when remote branch deletion fails, instead of returning only the GitHub API error.
  • Exposes the new cleanup mode through the ability schema, CLI flag, tool definition, and smoke coverage.

Why

Raw or permission-limited PR cleanup can successfully remove the managed DMC worktree and then fail deleting the remote branch with 403 Resource not accessible by integration. That made successful local lifecycle cleanup look like a total failure and obscured the state DMC is responsible for.

Testing

  • php tests/smoke-github-merge-pull-request.php
  • homeboy lint --path /Users/chubes/Developer/data-machine-code@fix-pr-cleanup-partial-success --extension wordpress --changed-since origin/main
  • homeboy test --path /Users/chubes/Developer/data-machine-code@fix-pr-cleanup-partial-success --extension wordpress --changed-since origin/main
  • git diff --check

AI assistance

  • AI assistance: Yes
  • Tool(s): OpenCode (GPT-5.5)
  • Used for: Diagnosing the DMC worktree cleanup lifecycle gap, implementing partial-success/local-only cleanup handling, updating smoke coverage, and running validation; Chris remains responsible for review and merge decisions.

@homeboy-ci
Copy link
Copy Markdown
Contributor

homeboy-ci Bot commented May 20, 2026

Homeboy Results — data-machine-code

Lint

lint — passed

ℹ️ Full options: homeboy docs commands/lint
ℹ️ Save lint baseline: homeboy lint data-machine-code --baseline
Deep dive: homeboy lint data-machine-code --changed-since 9aa81c3

Test

test — passed

ℹ️ Auto-fix lint issues: homeboy refactor data-machine-code --from lint --write
ℹ️ Collect coverage: homeboy test data-machine-code --coverage
ℹ️ Pass args to test runner: homeboy test -- [args]
ℹ️ Full options: homeboy docs commands/test
Deep dive: homeboy test data-machine-code --changed-since 9aa81c3

Audit

audit — passed

  • dead_code — 18 finding(s)
  • intra-method-duplication — 3 finding(s)
  • test_coverage — 3 finding(s)
  • repeated_literal_shape — 2 finding(s)
  • structural — 2 finding(s)
  • duplication — 1 finding(s)
  • requested_detectors — 1 finding(s)
  • Total: 30 finding(s)

Deep dive: homeboy audit data-machine-code --changed-since 9aa81c3

Tooling versions
  • Homeboy CLI: homeboy 0.188.14+e2d707b
  • Extension: wordpress from https://github.com/Extra-Chill/homeboy-extensions
  • Extension revision: f824bb03
  • Action: unknown@unknown

@chubes4 chubes4 merged commit a1a07bd into main May 20, 2026
5 checks passed
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