Design & media

Validation And Fix

Try it

Use when running existing project validation commands and fixing failures after code changes, including lint, type-check, unit/integration test, build, CI, or local script failures. Do not use when the task is to design or author new component/E2E tests; Chinese triggers include validation, check fa

What it does

1. 从 package.json 或仓库文档中识别可用命令。 2. 优先按以下顺序执行: - lint - type-check - unit/integration tests - build 3. 仔细阅读失败输出。 4. 将错误按文件、错误类型和依赖关系分组,优先处理阻塞后续诊断的根因。 5. 一次只修复一类问题,并显示或记录关键错误上下文。 6. 每次关键修复后重新执行受影响命令,确认错误是否减少。 7. 如果同一错误连续三次修复仍失败,停止扩大改动并报告阻塞。 8. 最后按 总结执行结果、修复内容和剩余风险。

The skill document

验证并修复

Purpose

自动化执行已有验证命令,分析失败原因并安全修复,确保质量门禁达标。

Procedure

  1. 从 package.json 或仓库文档中识别可用命令。
  2. 优先按以下顺序执行:
    • lint
    • type-check
    • unit/integration tests
    • build
  3. 仔细阅读失败输出。
  4. 将错误按文件、错误类型和依赖关系分组,优先处理阻塞后续诊断的根因。
  5. 一次只修复一类问题,并显示或记录关键错误上下文。
  6. 每次关键修复后重新执行受影响命令,确认错误是否减少。
  7. 如果同一错误连续三次修复仍失败,停止扩大改动并报告阻塞。
  8. 最后按 Expected Output 总结执行结果、修复内容和剩余风险。

Failure Triage

  • 先修最早出现且会级联的错误,例如缺失类型、导入失败、配置解析失败。
  • 区分真实产品 bug、测试环境问题、快照漂移、依赖版本变化和 flaky。
  • 对 CI 专属失败记录 Node 版本、包管理器、环境变量、路径大小写和工作目录差异。
  • 修复测试时优先修产品代码或测试等待方式,不用删除断言掩盖真实回归。

Constraints

  • 不要盲目关闭规则来消除报错
  • 除非有明确理由,不要为了通过检查而降低类型安全
  • 不要因为附近测试失败就顺手重写无关模块
  • 不要一次性修改多个无关根因
  • 不要删除失败测试来让验证通过
  • 不要只运行失败命令的片段就声称整体验证通过

详细参考

撰写验证修复报告时,加载 references/report-template.md。

Expected Output

  • lint / type-check / test / build 等验证命令全部通过
  • 失败项已修复或给出明确原因和后续行动
  • 修复报告保存为 reports/validation-fix-YYYY-MM-DD-HHmmss.md

Related skills

Run Git operations — commits, branches, merges, rebases, conflict resolution, and recovery — with safety rules enforced.

by Iván535 installs31 stars

Generate and edit Draw.io, Mermaid, and Excalidraw diagrams from natural language using a structured JSON spec.

by nssa.io1.0k installs47 stars

Find why your productivity system keeps failing, then apply the smallest fix — capacity math, bottleneck routing, durable local notes.

by Iván855 installs69 stars

Join a video meeting as an AI bot with voice, avatar, and screenshare across four operating modes.

by johnpatternai22 installs8 stars

Stores durable facts in a categorized, plain-markdown vault on disk, alongside your agent's built-in memory.

by Iván559 installs18 stars

More from bovinphang

Browse all skills

Generate or edit diagrams, visual assets, and image workflows with reviewable PNG self-checks and bounded self-repair.

by bovinphang9 installs1 stars

Use when creating editable technical diagrams with draw.io / diagrams.net sources, including architecture diagrams, ERD, UML, sequence diagrams, flowcharts, ML model diagrams, official shape lookup, brand symbols, Graphviz auto-layout, codebase structure maps, .drawio validation, or draw.io CLI expo

by bovinphang5 installs

Use when building, reviewing, or improving frontend UI that needs product-specific design direction, design-system generation, Master/Page overrides, distinctive visual identity, anti-generic interface choices, first-screen hierarchy, UI polish, chart UX, interaction states, responsive behavior, or

by bovinphang8 installs

Use when creating or reviewing Next.js 14+ App Router projects, file routes, layouts, server/client component boundaries, SSR/SSG/ISR, streaming, metadata, middleware, server actions, or Next-specific data fetching. For generic client React component architecture, apply the project's React conventio

by bovinphang10 installs1 stars

Use when creating, reviewing, or restructuring frontend monorepos with pnpm workspace, Turborepo, Nx, multi-package dependency boundaries, task orchestration, package naming, or package publishing; Chinese triggers include monorepo, workspace, multi-package.

by bovinphang10 installs1 stars

Use when creating or reviewing Nuxt 3 projects, file routes, pages, layouts, SSR/SSG/SPA behavior, Nuxt data fetching, route middleware, plugins, modules, server routes, or Nuxt-specific Vue 3 conventions. For generic Vue component architecture, apply the project's Vue conventions separately; Chines

by bovinphang10 installs1 stars