Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 23 additions & 3 deletions .qwen/skills/autofix/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,24 @@ owns the model-driven decisions, code changes, and pre-commit verification.
infra failure IS worth reporting: quote the exact command and its real output
in `<workdir>/failure.md` rather than skipping the check or guessing at the
cause (e.g. do not claim "node_modules is incomplete" unless you saw it fail).
- Bilingual PR-comment outputs: any file the workflow posts VERBATIM as a PR
comment — `address-summary.md`, `no-action.md`, and `e2e-report.md` — must be
written in English and END with a complete collapsed Chinese translation of
its content, mirroring the repository's PR-body convention:

```markdown
<details>
<summary>中文说明</summary>

…完整逐段翻译…

</details>
```

Translate the whole body, section by section; do not summarize or omit.
Keep `failure.md` and `handoff.md` English-only WITHOUT a details block:
handoff comments embed a byte-truncated excerpt of them, and a severed
`<details>` tag would swallow the rest of the comment when rendered.
- Never ask the user a question in this headless workflow. If blocked, write
`<workdir>/failure.md` with what you learned and stop.

Expand Down Expand Up @@ -108,7 +126,8 @@ Implement the selected issue in the checked-out repository:
8. Ensure `git status --short` shows only intended files, then create one
Conventional Commit, e.g. `fix(core): summary (#<issue>)`.
9. Write all required outputs:
- `<workdir>/e2e-report.md`
- `<workdir>/e2e-report.md` (bilingual per Shared Rules — it is posted
verbatim as a PR comment)
- `<workdir>/pr-title.txt`
- `<workdir>/pr-body.md` using `.qwen/skills/prepare-pr/SKILL.md`

Expand Down Expand Up @@ -146,6 +165,7 @@ Finish with exactly one outcome:
tests for touched packages (plus `npm run generate:settings-schema`, staging
the regenerated schema, if a settings source changed), commit once only after
they pass, then write `<workdir>/address-summary.md` with each feedback point,
decision, changes, conflict notes, and verification results.
- No change: write `<workdir>/no-action.md`.
decision, changes, conflict notes, and verification results (bilingual per
Shared Rules).
- No change: write `<workdir>/no-action.md` (bilingual per Shared Rules).
- Cannot confidently proceed: write `<workdir>/failure.md` and do not commit.
16 changes: 16 additions & 0 deletions scripts/tests/qwen-autofix-workflow.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -444,6 +444,22 @@ describe('qwen-autofix workflow', () => {
expect(skill).toContain('drop one silently');
});

it('requires bilingual bodies for files posted verbatim as PR comments', () => {
const skill = readAutofixSkill();
// Comment bodies mirror the repository's PR-body convention: English
// content ending with a complete collapsed Chinese translation.
expect(skill).toContain('<summary>中文说明</summary>');
expect(skill).toMatch(
/`address-summary\.md`, `no-action\.md`, and `e2e-report\.md`/,
);
// failure/handoff excerpts are byte-truncated into handoff comments; a
// severed <details> tag would swallow the rest of the comment, so those
// two files must stay English-only.
expect(skill).toContain(
'Keep `failure.md` and `handoff.md` English-only WITHOUT a details block',
);
});

it('includes issue-level comments in review feedback scanning', () => {
const reviewScanStep =
workflow.match(
Expand Down
Loading