Fix code quality issues identified in a code quality review stored in agent_artefacts/code_quality/<topic>/. Systematically addresses issues found by the code-quality-review-all skill for ANY code quality topic, with validation and testing at each step. Use when user asks to fix issues from a code quality review, or asks to fix issues from agent_artefacts/code_quality/<topic>.
Fix code quality issues identified in a code quality review. This skill systematically addresses issues found by the code-quality-review-all skill for ANY code quality topic, with validation and testing at each step.
When invoked, this skill expects the path to a code quality topic as an argument (e.g., agent_artefacts/code_quality/private_api_imports).
If not provided, the skill will ask the user for the topic path. Within the topic path, there are several files:
Filters and options are specified interactively after the skill starts by using the AskUserQuestion tool to present options unless specified otherwise in arguments.
Read topic documentation
Analyze and categorize issues
Ask user for filtering preferences
AskUserQuestion tool to ask:
Validate understanding of fixes
<topic>/README.md with findingsFor each issue to be fixed:
Read and understand context
Validate the suggested fix
Estimate change scope
agent/<short_description_of_issue>Verify changes compile/parse
Track progress
Run linting
Run unit tests
Identify test files for each modified evaluation
Run unit tests for affected evaluations using pytest:
Basic test commands:
# Install relevant packages in the event of import failure
uv sync --group test
# Run tests for a specific evaluation
uv run pytest tests/<evaluation_name>/
# Run a specific test file
uv run pytest tests/test_file.py
# Run a specific test
uv run pytest tests/test_file.py::TestClass::test_method
# Run slow tests (excluded by default)
uv run pytest --runslow tests/
# Skip dataset download tests
uv run pytest -m 'not dataset_download' tests/
# Run only slow tests
uv run pytest -m slow tests/
Test markers to be aware of:
@pytest.mark.slow - Tests taking >10 seconds
@pytest.mark.dataset_download - Tests that download datasets
@pytest.mark.docker - Tests using Docker
@pytest.mark.huggingface - HuggingFace-related tests
Focus on tests for the specific evaluation
Look for test failures or errors
IMPORTANT: Do NOT run full evaluations (they take too long) unless user explicitly requests it
Handle test failures
Update results.json with fix status
For each issue that was fixed, add "fix_status" field after "suggested_fix":
{
...
"suggested_fix": "...",
"fix_status": "fixed - please review"
}
For issues that couldn't be fixed, add explanation:
"fix_status": "not fixed - reason: ..."
IMPORTANT: Do NOT remove any entries from results.json - only add/update "fix_status"
The code-quality-review-all skill owns results.json and is responsible for removing entries
Re-run code quality review
Fix remaining issues if in scope
Update topic's README.md
Update SUMMARY.md
Run markdown linters
uv run pre-commit run markdownlint-fix to fix markdown linting issuesCreate/Update PR description (cumulative)
Read existing PR_DESCRIPTION.md if it exists (from previous runs)
Cumulative tracking: PR description represents ALL changes from branch base, not just this run
If PR_DESCRIPTION.md exists:
If PR_DESCRIPTION.md doesn't exist (first run):
Format for GitHub/GitLab pull request with:
Use proper markdown formatting for PR readability
IMPORTANT: Do NOT commit PR_DESCRIPTION.md - it's only for creating the PR
Example structure:
## Summary
Fix private API imports code quality issues across evaluations.
## Overall Changes
- Total issues fixed: 25
- Evaluations affected: 8
## Fix Sessions
### Session 1: 2026-01-18 10:30 (Easy issues)
- Fixed 10 easy issues
- Targeted: Easy complexity, All evaluations
### Session 2: 2026-01-18 14:15 (Medium issues)
- Fixed 15 medium issues
- Targeted: Medium complexity, Specific evaluations
## Fixed Issues
[Table of all fixed issues from all sessions]
## Testing
[Latest test results]
## Remaining Issues
6 issues remain (4 hard, 2 require investigation)
## Review Notes
- Session 1: All tests passed
- Session 2: One test required adjustment in fortress/scorer.py
Present results to user
Offer next steps
npx skills add UKGovernmentBEIS/code-quality-fix-all下载完整 Skill 目录,包含 SKILL.md 及所有相关文件
Search for places (restaurants, cafes, etc.) via Google Places API proxy on localhost.
Interact with GitHub using the `gh` CLI. Use `gh issue`, `gh pr`, `gh run`, and `gh api` for issues, PRs, CI runs, and advanced queries.
Create or update AgentSkills. Use when designing, structuring, or packaging skills with scripts, references, and assets.
Start voice calls via the OpenClaw voice-call plugin.
Notion API for creating and managing pages, databases, and blocks.
Gemini CLI for one-shot Q&A, summaries, and generation.
Category:developer