Skip to content

fix(skills): handle compound git porcelain status codes in draft_commit_message (PER-185)#152

Open
Shadowsong27 wants to merge 2 commits into
mainfrom
feat/per-185-compound-porcelain-codes
Open

fix(skills): handle compound git porcelain status codes in draft_commit_message (PER-185)#152
Shadowsong27 wants to merge 2 commits into
mainfrom
feat/per-185-compound-porcelain-codes

Conversation

@Shadowsong27
Copy link
Copy Markdown
Owner

Summary

  • derive_type() was checking single-char codes (A, ' A', etc.) which never matched real two-char porcelain output like AM, AD, MM, RM.
  • Switch to a per-column check: a path is "new" iff either column in the two-char porcelain code is A, ?, R, or C.
  • Update docstring + inline mapping table to document the per-column semantics.
  • 6 new test cases under TestCompoundPorcelainStatusCodes: AM, AD, MM, RM, ' D', 'D '.

Closes PER-185.

Test plan

  • pytest libs/beacon/tests/unit/data/skills/contribute_warehouse/test_draft_commit_message.py → 34 passed
  • ruff check on touched files → clean
  • CI green
  • opencode-review bot clean

🤖 Generated by diligent-supervisor / delegate-to-oc (kimi-for-coding/k2p6)

…it_message.py

Git porcelain status codes are two-character (index column + worktree
column). The previous check only matched single-character codes like
'A' or '??', causing compound codes such as AM, AD, MM, RM to fall
through to the wrong commit type.

- Treat a file as 'new' (→ feat) when either column is A, ?, R, or C.
- Update the inline mapping-table comment to document per-column
  semantics.
- Add unit tests for AM, AD, MM, RM, D , D  codes.

Closes PER-185.
@github-actions
Copy link
Copy Markdown
Contributor

OpenCode Review

Model: openai/gpt-5.5
Reviewed commit: b0da56420ba91797eb098c9b635d83fd1e930b74
Workflow run: https://github.com/Shadowsong27/agentic-beacon/actions/runs/26092834839

Findings

No findings.

Open Questions

None.

Notes

  • The changed status handling correctly treats two-column porcelain statuses with A, ?, R, or C in either column as new for skills/ and agents/.
  • Tests cover the important compound statuses introduced by this behavior change.

Token Usage

Input tokens: 6614
Output tokens: 74
Reasoning tokens: 34
Cache read tokens: 6144
Cache write tokens: 0
Total tokens: 12866

@Shadowsong27
Copy link
Copy Markdown
Owner Author

Supervisor triage — bot round 1

Bot reviewed commit: b0da5642.

Findings

  • None.

Notes / residual risks (bot's "Notes" section)

  • "Tests cover the important compound statuses introduced by this behavior change."
    • Decision: acknowledged, no action.

PR is READY. CI green.

🤖 diligent-supervisor

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