agent-sandbox: Skill for Claude Code

.agents/skills/fix-flakes/SKILL.md

fix-flakes is a skill for Claude Code, Codex from kubernetes-sigs/agent-sandbox. It costs 80 tokens per session (1,144 once invoked), scanned A, original, Apache-2.0.

A procedure for investigating and fixing flaky tests in the Kubernetes agent-sandbox project. A flaky test sometimes passes and sometimes fails without a relevant code change.

In plain words
What is it for?
Use it to reproduce open flake issues, inspect failing logs, apply a minimal fix, and open a pull request linked to the issue.
Why use it?
It requires evidence of the failure before editing, helping avoid changing tests based on guesses or infrastructure-only problems.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: installed under .agents/ (shared by several agents); mentions AGENTS.md.

This is kubernetes-sigs/agent-sandbox's own configuration. It tells Claude Code and Codex how to work on agent-sandbox itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything agent-sandbox configures →

About the project

Agent Sandbox is a Kubernetes extension for managing isolated, stateful workloads that run as single long-lived containers with stable identities and persistent storage. It is intended for AI agent runtimes, reinforcement-learning workloads, and other applications that do not fit ordinary stateless deployments. Its catalogue skills and instructions support operating these sandbox workloads.

kubernetes-sigs/agent-sandbox · 3,765 stars · on GitHub · agent-sandbox.sigs.k8s.io

Reuse

Borrowing it

Nothing to install: this file belongs to kubernetes-sigs/agent-sandbox. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/kubernetes-sigs/agent-sandbox/main/.agents/skills/fix-flakes/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/kubernetes-sigs/agent-sandbox

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for fix-flakes

README.md
[![agentmods](https://agentmods.dev/badge/skills/kubernetes-sigs/agent-sandbox/fix-flakes.svg)](https://agentmods.dev/skills/kubernetes-sigs/agent-sandbox/fix-flakes)
Your own site
<a href="https://agentmods.dev/skills/kubernetes-sigs/agent-sandbox/fix-flakes"><img src="https://agentmods.dev/badge/skills/kubernetes-sigs/agent-sandbox/fix-flakes.svg" alt="Measured on agentmods" height="20"></a>
Per session 80 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,144 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 1 finding, up to high

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • high Privilege Escalation · line 39
    Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
    Fix: Remove references to credential paths. Use environment variables or secrets managers. For docs, use placeholder paths (e.g., /path/to/config). Never load .env or token files in production code paths.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00080 $0.01144
Opus 5 $0.00040 $0.00572
Sonnet 5 $0.00016 $0.00229
Haiku 4.5 $0.00008 $0.00114

Measured 8d ago against content hash b8f1f592dcb3, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

fix-flakes scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.agents/skills/fix-flakes/SKILL.md · 85 lines

How it starts

The opening of the file, as written. The whole thing — 85 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Fix flaky tests from kind/flake issues

Work through open kind/flake issues (filed nightly by dev/tools/flake-report), reproduce each flake, land a minimal fix, and open a PR that closes the issue. Evidence before edits: never change a test you could not observe failing or whose failure output you have not read.

Inputs

  • A specific issue number, if the caller gives one; otherwise discover work: gh issue list --repo kubernetes-sigs/agent-sandbox --label kind/flake --state open --json number,title,body
  • Skip any issue that already has an open fix PR: search gh pr list --repo kubernetes-sigs/agent-sandbox --state open --search "<issue number> in:body" and check the results actually reference Fixes #<n> / Closes #<n>.
  • Skip infra-failure issues (title contains "infrastructure failures") unless explicitly asked — those are CI tooling work (dev/ci/, prow job config in kubernetes/test-infra), not test edits. If you do take one, the fix lives in dev/ci/shared/runner.py retries, image prepulls, or job resources.

Reproduce first

  1. Read the issue: test name, tab/job, failure timestamps, job-history link. Fetch a failing run's junit + build log from the GCS links to read the real error before touching anything.
  2. Locate the test: git grep -n "func <TestName>(" (Go) or git grep -n "def <test_name>(" (Python SDK e2e). For a Go subtest (TestFoo/subtest), grep for the parent (func TestFoo() only — the part before the first / — then find the t.Run("subtest", ...) inside it.
  3. Stress it:
    • Unit tests: go test ./<package>/... -run '^<TestName>$' -race -count=50 (for a subtest, -run '^TestFoo$/^subtest$')
    • e2e tests need a cluster: make deploy-kind first (see AGENTS.md), then go test ./test/e2e/... -run '^<TestName>$' -count=10 with KUBECONFIG=bin/KUBECONFIG.
  4. If it will not reproduce locally after a reasonable stress run, do NOT guess-fix. Analyze the CI failure output instead; if the cause is still unclear, post your findings as a comment on the issue and stop.

Read the full file on GitHub · 85 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 8d ago First seen · 85 lines · 80 tokens per session scan A b8f1f592dcb3

Subscribe to this mod's changes

fix-flakes is a skill published in the GitHub repository kubernetes-sigs/agent-sandbox (3,765 stars, last pushed 3d ago), licensed Apache-2.0. It adds 80 tokens to every session and 1,144 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

fix-failing-tests

Diagnose a failing test in the googleapis/mcp-toolbox repo and land a fix by reasoning from the actual error: read the failure, reproduce it, shrink it until the cause is forced into the open, then fix the cause. Use this whenever a test or CI job is red, a build breaks after a change, many packages fail at once, or a…

googleapis/mcp-toolbox · 87 tokens

troubleshoot-sandbox

Troubleshoot OpenSandbox issues by running diagnostics (logs, inspect, events, summary) via CLI or HTTP API to diagnose sandbox failures like OOM, crash, image pull errors, network problems, etc.

opensandbox-group/OpenSandbox · 48 tokens

langsmith-observability

LLM observability platform for tracing, evaluation, and monitoring. Use when debugging LLM applications, evaluating model outputs against datasets, monitoring production systems, or building systematic testing pipelines for AI applications.

synthetic-sciences/openscience · 45 tokens

routing-calibration

Use when calibrating or validating a maintained routing recipe against live model backends, including probe manifests and evidence reports.

vllm-project/semantic-router · 27 tokens

verification

Prove that a coding task is actually complete. Use this after meaningful code changes, when tests/builds fail or are skipped, before marking a plan or goal complete, and whenever acceptance depends on runtime, security, recovery, performance, or cross-module evidence.

ageerle/ruoyi-ai · 54 tokens

ulw-qa

This is a Hermes-native ultraqa workflow skill.

rlaope/oh-my-hermes · 57 tokens