Skip to content

skills(running-tend): don't restate mention-handler analysis in reviews - #2656

Closed
worktrunk-bot wants to merge 3 commits into
mainfrom
skills/dedup-cross-workflow-25611071907
Closed

worktrunk-bot wants to merge 3 commits into
mainfrom
skills/dedup-cross-workflow-25611071907

Conversation

@worktrunk-bot

Copy link
Copy Markdown
Collaborator

Summary

Adds a cross-workflow dedup rule to running-tend for the case where tend-mention handles a maintainer comment (push + reply), and the resulting synchronize triggers tend-review, which re-states the same analysis in the review body.

This is the pattern flagged in #2655 (comment): the bot answered the same "more opencode-native approach" question twice in five minutes — once in the mention-handler reply at 19:37 and again in the review body at 19:42.

Why this rule, not a workflow change

The bundled review skill already says "check whether a bot reply exists after the question's timestamp before answering", but scopes it to inline comments specifically. The new rule extends the dedup expectation to the review body and summary, and names the cross-workflow shape explicitly so future review runs catch it.

Notes

  • The bundled tend-review skill probably wants the same tightening; happy to file an upstream issue against max-sixty/tend separately.
  • No code change — this is documentation that surfaces in the review prompt.

Test plan

  • Maintainer eyeballs the wording and confirms it matches the intent of the original feedback.

worktrunk-bot and others added 3 commits May 9, 2026 17:35
`opencode_plugins_dir()` previously fell back to `dirs::config_dir()`,
which on macOS returns `~/Library/Application Support`. OpenCode itself
treats that path as the *managed* settings directory and looks for user
plugins under `~/.config/opencode/` on every OS, so the plugin landed in
the wrong place on macOS — its in-code docstring already claimed it was
written to `~/.config/opencode/plugins/`, but the runtime disagreed.

Mirror OpenCode's documented global-config precedence instead:
`$OPENCODE_CONFIG_DIR` > `$XDG_CONFIG_HOME/opencode` > `~/.config/opencode`.
The Linux behaviour is unchanged; macOS now matches the docs and the
existing CLI help text.

Closes #2654

Co-Authored-By: Claude <[email protected]>
The install path now follows OpenCode's documented config precedence
(OPENCODE_CONFIG_DIR > XDG_CONFIG_HOME/opencode > ~/.config/opencode),
but the help text still named only OPENCODE_CONFIG_DIR. A user with
XDG_CONFIG_HOME set saw the plugin land somewhere other than the help
text suggested.
Adds a cross-workflow dedup rule for the case where tend-mention pushes a
fix + posts a reply, and the resulting synchronize triggers tend-review,
which then re-states the same analysis in the review body.

Co-Authored-By: Claude Opus 4.7 <[email protected]>
@max-sixty

Copy link
Copy Markdown
Owner

@tend-agent: two things went quite wrong here:

  • this is a problem with tend, not worktrunk; the agent should have asked to put an issue into tend
  • it has the opencode work here; it should have reset to main

can you debug, evaluate what went wrong, and make the appropriate changes?

@max-sixty

Copy link
Copy Markdown
Owner

@worktrunk-bot put an issue in about the original issue, into tend

@worktrunk-bot

Copy link
Copy Markdown
Collaborator Author

Investigated — two things went wrong:

Wrong target. The dedup rule belongs in tend's bundled plugins/tend-ci-runner/skills/review/SKILL.md, not as a per-repo overlay. This should have been a tend issue from the start. The bundled skill is what fires for every tend consumer; an overlay only fixes worktrunk and leaves the same gap on every other repo. As it turns out, max-sixty/tend#400 was filed by tend-agent at 20:50Z (12 minutes after I opened this PR) covering the exact same ground — review-body scope and cross-workflow tend-mention → tend-review overlap, with #2655 cited as the same incident I drew from. Skipping a duplicate filing on the basis of #400; happy to file a fresh one if you'd rather not piggy-back on tend-agent's.

Branch wasn't reset to main. I branched off fix/issue-2654 (PR #2655's branch) instead of origin/main, so b7612475 and 9bd59311 (the two opencode commits, both already in #2655) landed in this PR's diff. The check that would have caught this — verifying the base is origin/main before staging an unrelated commit — wasn't applied.

Closing.

@tend-agent

Copy link
Copy Markdown

Both gaps are now captured in tend: max-sixty/tend#400 for the cross-workflow dedup (review-body / tend-mention → tend-review), and max-sixty/tend#402 for the branch-base verification rule that would have flagged fix/issue-2654 as a non-origin/main base. The skill changes belong in tend's bundled plugins/tend-ci-runner/skills/, so I'm leaving worktrunk alone here and following up in tend.

@max-sixty
max-sixty deleted the skills/dedup-cross-workflow-25611071907 branch June 18, 2026 06:00
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.

3 participants