Agent Skills
› dartsim/dart
› dart-ci
dart-ci
GitHub用于调试 DART 项目的 CI/CD 失败及 GitHub Actions。提供监控 PR 检查、查看运行日志、重试失败作业等 CLI 命令,列出格式化、Codecov、平台特定崩溃等常见故障的解决方案,并说明各工作流架构及 CUDA Runner 的安全策略。
触发场景
CI 构建或测试失败
需要查看或监控 GitHub Actions 运行状态
遇到 FreeBSD RTTI、macOS SEGFAULT 等平台特定问题
涉及 CUDA 编译或 GPU 运行时验证
安装
npx skills add dartsim/dart --skill dart-ci -g -y
SKILL.md
Frontmatter
{
"name": "dart-ci",
"description": "DART CI: GitHub Actions, cache debugging, and platform-specific failures"
}
DART CI/CD Troubleshooting
Load this skill when debugging CI failures or working with GitHub Actions.
Quick Commands
# Monitor PR checks
gh pr checks <PR_NUMBER>
gh pr checks <PR_NUMBER> --watch --interval 30 --fail-fast
# View run details
gh run list --branch <BRANCH> -e pull_request -L 20
gh run watch <RUN_ID> --interval 30
gh run view <RUN_ID> --json status,conclusion,url
# Debug failures
gh run view <RUN_ID> --job <JOB_ID> --log-failed
gh run view <RUN_ID> --json jobs --jq '.jobs[] | {name, databaseId}'
# Rerun failed jobs only after explicit maintainer/user approval
gh run rerun <RUN_ID> --failed
gh run rerun <RUN_ID> --job <DATABASE_ID>
Full Documentation
For complete CI/CD guide: docs/onboarding/ci-cd.md
Common Failure Modes
| Failure Type | Solution |
|---|---|
| Formatting fails | pixi run lint; push only after approval |
| Codecov patch fails | Add tests for uncovered lines |
| FreeBSD RTTI fails | Use type enums + static_cast instead of dynamic_cast |
| macOS ARM64 SEGFAULT | Replace alloca()/VLAs with std::vector<T> |
| RTD build fails | Use defensive .get(key, default) patterns |
| gz-physics fails | Reproduce with pixi run -e gazebo test-gz |
Workflow Architecture
| Workflow | Purpose | Platforms |
|---|---|---|
ci_lint.yml |
Formatting | Ubuntu |
ci_ubuntu.yml |
Build + test + coverage | Ubuntu |
ci_macos.yml |
Build + test | macOS |
ci_windows.yml |
Build + test | Windows |
ci_freebsd.yml |
Build + test (VM) | FreeBSD |
ci_gz_physics.yml |
Gazebo integration | Ubuntu |
ci_cuda.yml |
CUDA compile + smoke | Ubuntu/GPU |
CUDA Runner Policy
The project has a trusted ubuntu-latest-gpu runner for same-repository CUDA
runtime validation, but it must never run untrusted fork-PR code. Consequences:
- Same-repository PRs, protected branch pushes, and manual dispatches use the
GPU runner and run
pixi run --locked -e cuda test-cuda. - Fork PRs use a GitHub-hosted fallback and compile CUDA targets without running GPU-only steps.
- Local CUDA validation is
pixi run -e cuda test-allon Linux hosts with a visible NVIDIA CUDA runtime; local Pixi config auto-detects visible GPU compute capabilities forDART_CUDA_ARCHITECTURES. pixi run check-phase5-cuda-workflowenforces the trusted-event GPU guard and fork-PR hosted fallback inci_cuda.yml.
Fast Iteration Loop
- Identify failing step from job logs
- Reproduce locally with same build toggles
- Fix the smallest failing test
- Push only after explicit maintainer/user approval, then monitor:
gh run watch <RUN_ID>
Caching
- sccache/ccache reduces build time 50-70%
- Check cache hit rates in workflow logs
- Force cache bust by changing cache key if needed
Expected CI Times
| Platform | Cached | Uncached |
|---|---|---|
| Ubuntu | 20-30 min | 45-60 min |
| macOS | 15-25 min | 30-45 min |
| Windows | 15-20 min | 25-35 min |
版本历史
- e0d13fd 当前 2026-07-05 10:37


