Code Review

VerifiedCaution

Review code for potential issues and improvements, following a rigorous methodology with subagents and evidence-based reporting.

Sby Skills Guide Bot
DevelopmentAdvanced
7/22/2026
Claude Code
#code-review#security-audit#cross-platform#static-analysis#subagents

Recommended for

Automated summary

Performs a focused code review of specific files or functions, verifying each potential issue by tracing the full call chain and using subagents before reporting it.

Strengths

  • Requires concrete evidence (a failing scenario, a caller search) before any issue is reported, which keeps false positives down
  • Starts by reading project documents (CLAUDE.md, CONTRIBUTING.md, gotchas) and the ESLint, tsconfig and clang-tidy configs so the review matches real conventions
  • Explicitly covers correctness, code quality, security, cross-platform safety (RAII, Node-API) and refactoring
  • Accepts a clean result: allows "No issues found" instead of padding the list

Limitations

  • Tightly coupled to a specific repo layout (doc/C++_REVIEW_TODO.md, Node-API v9, ESLint security plugin) that is hard to reuse elsewhere
  • Relies heavily on Claude Code subagents for exploration and validation, so it ports poorly to other editors
  • Reads lint configuration files but does not describe actually running the linters
When to use it

Use it when you need a rigorous, evidence-backed review of a file, function or diff before merging, especially for native C++ or security-sensitive code.

When not to use it

Avoid it for a quick style or formatting pass, or when you want product-level improvement ideas rather than confirmed bugs.

Security analysis

Caution
Quality score78/100

The skill is a code-review procedure with no harmful payload: no curl|sh, no rm -rf, no secret exfiltration, no obfuscated commands, and no attempt to disable safety checks. Its risk comes only from the broad tool grant (Bash/Write/Edit/WebSearch) requested for a review task and from referencing tools (subagents, AskUserQuestion) that are not in its declared allowed-tools, which could lead to unanticipated tool use. That places it in 'caution' rather than 'safe' or 'risky'.

Findings
  • •Declares broad execution/write tools (Bash, Edit, Write) plus WebSearch for what is nominally a read-only review task; no constraints are given on how Bash is used.
  • •References a subagent tool and `AskUserQuestion` which are not part of the declared allowed-tools, so the skill may attempt tool calls outside its declared capability surface.
  • •No destructive, exfiltrating, or obfuscated instructions found; the body is purely a review methodology.
How this analysis is made

Examples

Review a native C++ file
Review src/platform/win/path_utils.cc for memory management issues and Windows path handling bugs before I merge.
Check a diff for real bugs
Can you review the changes in src/config/parser.ts? I only want verified bugs, not stylistic suggestions.
Security review of a function
Review the readConfig() function in src/config/index.ts for path traversal and injection issues.

name: review description: Review code for potential issues and improvements. Use when asked to review specific files, functions, or code sections. allowed-tools: Bash, Read, Glob, Grep, Edit, Write, WebSearch

Code Review

Review the mentioned code for potential issues and improvements.

Before you start

Study the following project documents before reviewing:

  • CLAUDE.md — project conventions, critical knowledge, anti-patterns, and CI/CD constraints
  • CONTRIBUTING.md — development setup, pre-commit checklist, npm script naming conventions
  • doc/gotchas.md — platform-specific quirks, timeout issues, testing pitfalls
  • doc/C++_REVIEW_TODO.md — C++ review checklist (memory management, RAII, platform API usage, security validation)

Also check these configuration files for applicable rules:

  • eslint.config.mjs — ESLint rules including security plugin
  • tsconfig.base.json — strict TypeScript settings (exactOptionalPropertyTypes, noUncheckedIndexedAccess, etc.)
  • .clang-tidy — C++ static analysis checks (bugprone, performance, clang-analyzer)

Only report verified bugs, things that are actually wrong. Do NOT report:

  • Speculative future risks ("if someone later removes this guard...")
  • Feature requests or suggestions disguised as issues
  • Things you haven't proven with concrete evidence from the codebase

For EVERY potential issue, you MUST complete these steps before reporting:

  1. Read the actual code (not just the diff). Follow the full call chain
  2. Search for all callers/usages to understand context
  3. Read any design docs or TPPs that explain the rationale
  4. Construct a concrete failing scenario. If you can't describe exactly how the bug manifests, it's not an issue
  5. Discard it if your research shows it's intentional or already handled

Use subagents liberally:

  • Exploration: When more than three files need review, or the code is complex, launch Explore subagents (one per file/area) to gather findings
  • Validation: Before reporting ANY issue, launch a subagent to verify it. Have it trace the full call chain, search for guards/handlers you might have missed, and read relevant design docs. If the subagent can't confirm the bug, discard the issue
  • Iteration: After your initial analysis, launch a second round of subagents to dig deeper into the most promising findings. Check edge cases, race conditions, and interaction effects between changed files

If you find zero real issues after thorough research, say "No issues found." Do not pad the list.

What to look for

Correctness

  • Logic or implementation errors
  • If correct but surprising, suggest a clearer equivalent or a comment
  • Don't trust docs or implementation as authoritative. If they disagree, flag it, consider what you think is correct (it may be neither!), and explain your reasoning

Code quality

  • Violations of project design principles or coding standards
  • Dead code (suggest deleting it)
  • Comments that merely restate the function name (suggest removing)

Cross-platform safety

  • C++ code must use RAII for all resource management (no raw malloc/free, no leaked CoreFoundation refs, no unclosed handles)
  • Path handling must account for platform differences (UNC paths on Windows, symlinks, mount points)
  • Native code must use Node-API v9 correctly (proper ref counting, error propagation, async worker lifecycle)

Security

  • Path traversal or injection vulnerabilities (verify realpath/canonicalization)
  • Buffer overflows or integer overflow in string conversions
  • Unsafe use of child_process, eval, non-literal require (per eslint-plugin-security)
  • Thread safety issues in C++ (std::atomic vs volatile, data races)

Refactoring

  • Duplicated logic across platform implementations that could be shared
  • Overly complex functions that should be decomposed
  • Abstractions that no longer fit (or missing abstractions that cause repeated code)
  • Do NOT flag naming preferences or stylistic choices

Testing gaps

  • Missing coverage for critical paths or edge cases
  • Tests that use anti-patterns from CLAUDE.md (arbitrary timeouts, forcing GC, setImmediate in afterAll)
  • Dynamic filesystem values tested with exact equality instead of type checks
  • Missing Windows retry logic for directory cleanup

TypeScript strictness

  • Code must compile under the project's strict settings (exactOptionalPropertyTypes, noUncheckedIndexedAccess, etc.)
  • No inline imports — use standard top-level imports
  • Scripts must be .ts executed with tsx, never .js/.mjs/.cjs

Response format

  1. Completely omit any issues that are irrelevant after research and analysis.
  2. Sort remaining issues by severity (Critical > High > Medium > Low).

For each issue use a short ID (e.g. #A, #B) and include:

  • Priority: Critical / High / Medium / Low
  • Problem: What's wrong, why, and the concrete scenario where it fails
  • Proof: The specific code path or test that demonstrates the bug
  • Solution: A concrete fix
  • Location: File and line reference

Emit detailed findings, and then use AskUserQuestion with checkboxes for each item so the user can accept, veto, or comment on each one individually.

From the file to a first result

The download contains exactly the content displayed on this page. This copy may differ from the latest version in the source repository.

View the source and supporting files

This download contains SKILL.md only. Any scripts, references, templates and dependencies are not included. Get the required files from the source, preserving their directory structure, before continuing.

1. Download the file

Download SKILL.md

From the root of a test project, save the file as .skill-downloads/code-review-mrwak993/SKILL.md, or use the command below. This folder is for inspecting the skill before installation.

Command for macOS/Linux or WSL: requires a POSIX shell and curl. On Windows without WSL, use the download button and create the folder manually.

mkdir -p '.skill-downloads/code-review-mrwak993' && curl --fail --show-error --location 'https://skills-guides.com/api/skills/code-review-mrwak993/download' --output '.skill-downloads/code-review-mrwak993/SKILL.md.part' && mv '.skill-downloads/code-review-mrwak993/SKILL.md.part' '.skill-downloads/code-review-mrwak993/SKILL.md'

2. Check prerequisites

Read SKILL.md before using it. If it references scripts or external services, inspect them and prepare the required access in your test environment.

Tools declared by the author (check availability in your agent): Bash, Read, Glob, Grep, Edit, Write, WebSearch

No recognized prerequisites section in this file. This does not mean it is self-contained: libraries, tools and access requirements may be mentioned elsewhere in the content or source repository.

The platforms on this page are catalog indications. The paths below follow tool documentation; they do not prove this skill has been run in those tools. No minimum tool version is confirmed for this listing.

3. Load the skill

After inspection, copy the complete folder into your project using one of the commands below, then open a new tool session. The command stops if a folder with the same name already exists: compare the files before replacing it.

Claude Code
test -f '.skill-downloads/code-review-mrwak993/SKILL.md' && test -s '.skill-downloads/code-review-mrwak993/SKILL.md' && mkdir -p '.claude/skills' && test ! -e '.claude/skills/review' && cp -R '.skill-downloads/code-review-mrwak993' '.claude/skills/review'

OpenSkills

OpenSkills must already be installed. The local install/read procedure is checked with OpenSkills 1.5.0, which requires Node.js ≥ 20.6.0. Catalog slugs are not resolved automatically.

Official OpenSkills installation
openskills install './.skill-downloads/code-review-mrwak993'

openskills read 'code-review-mrwak993'

Reading should display the installed file content and its base directory. It does not run the skill or install its dependencies.

For an agent that reads AGENTS.md, then sync the index. This command changes AGENTS.md: review the diff before using it.

openskills sync

Manual method or another tool: attach SKILL.md to a conversation, or open it in an agent that can read files. Include any required supporting resources. No universal folder is recognized by every tool.

4. Try a first task

Use a short, synthetic input: an API endpoint, a small document or an interface brief. In a new conversation, attach the file or give the agent its path, then adapt this request:

Read .skill-downloads/code-review-mrwak993/SKILL.md and apply its instructions to this example: [describe a test input]. Identify any missing files, dependencies or access. Produce the result requested by the skill without inventing data or running unreviewed scripts.

Expected result: output matching the skill instructions, or a precise list of missing prerequisites. A read confirmation alone does not validate a first use. If an external resource is unavailable, that path remains untested.

Related skills