kotkan/claude-plugin-inference-arbitrage#30 reported "FAIL repo =
kotkan/worktree-discipline (want kotkan/claude-plugin-worktree-discipline)".
Investigation found no stale reference in this repo's source or fixtures —
the expected value already matches the live repo (verified: only
kotkan/claude-plugin-worktree-discipline exists on Gitea; the pre-rename
bare-name slug is a redirect only). The failure came entirely from the live
git remote of the sibling ../worktree-discipline checkout on disk, which is
outside this repo and outside version control, so it can drift independently
(e.g. an old clone never repointed after the 2026-07-22 kotkan rename). That
also meant the assertion silently never ran in CI, since the bare CI
container has no sibling checkout and the test just printed "skip".
Replace the dependency on that external checkout with a throwaway git repo
created inside the test's own tmpdir, with its remote set explicitly to the
current repo slug. Same code path (resolve_repo/parse_remote in
bin/filing-plan) is exercised deterministically, and the assertion now
always runs instead of skipping outside a workspace with that sibling
checkout present.
Verified the new test both passes against the correct remote and correctly
reproduces the exact original failure signature when pointed at the stale
pre-rename slug.
Root cause: bin/filing-plan and references/issue-template.md always render
the ia-candidate marker HTML-comment-wrapped. A direct issue_write probe
confirmed the Gitea MCP write path preserves a literal <!-- --> unchanged, so
the loss on oleks/claude-plugin-cluster#56 and #57 happened on the
Agent(anxious:issuer-agent) relay hop: an HTML comment is invisible when its
surrounding text is read as markdown, so an agent relaying "what the body
should say" instead of pasting it verbatim can silently drop it.
Two fixes:
- bin/filing-plan: find_existing()'s marker_re() now also matches the bare,
unwrapped "ia-candidate: <id>" line (end-of-line anchored, not \b, since
candidate ids contain "-" and a word-boundary check would false-match a
longer id sharing a prefix) so already-filed issues like cluster#56/#57
are still recognized and not duplicate-filed.
- skills/offload-audit/SKILL.md: the issuer delegation prompt now fences the
rendered body in its own code block and explicitly warns that the leading
marker is an invisible-by-design HTML comment, not stray syntax to clean
up, instead of inlining it as bare markdown the relaying agent could read
right through.
references/issue-template.md documents both, and tests/filing.test.sh adds
coverage for the bare-marker match plus a same-prefix-different-id
non-match case.
Bumps plugin.json to 0.7.1.