crash-risk-audit

crash-risk-audit is a skill for Claude Code, Codex from cruisediary/apple-app-review-skills. It costs 45 tokens per session (1,873 once invoked), scanned A, original, MIT.

A Swift code audit that finds force unwraps, force casts, force try, and other patterns that can crash an app when data is missing or has an unexpected type. Swift is Apple's programming language for iOS and macOS apps.

In plain words
What is it for?
Use it on Swift projects before submission to locate crash-prone code paths that need safer handling.
Why use it?
It helps expose crashes that may occur with unusual server responses or test data during App Store review.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it on Swift projects before submission to locate crash-prone code paths that need safer handling.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/cruisediary/apple-app-review-skills/crash-risk-audit
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add cruisediary/apple-app-review-skills --skill crash-risk-audit
Clone the repo
git clone --depth 1 https://github.com/cruisediary/apple-app-review-skills

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 crash-risk-audit

README.md
[![agentmods](https://agentmods.dev/badge/skills/cruisediary/apple-app-review-skills/crash-risk-audit/github.svg)](https://agentmods.dev/skills/cruisediary/apple-app-review-skills/crash-risk-audit)
Your own site
<a href="https://agentmods.dev/skills/cruisediary/apple-app-review-skills/crash-risk-audit"><img src="https://agentmods.dev/badge/skills/cruisediary/apple-app-review-skills/crash-risk-audit/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for crash-risk-audit

Your own site · 80×15
<a href="https://agentmods.dev/skills/cruisediary/apple-app-review-skills/crash-risk-audit"><img src="https://agentmods.dev/badge/skills/cruisediary/apple-app-review-skills/crash-risk-audit.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 45 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,873 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.
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.00045 $0.01873
Opus 5 $0.00023 $0.00937
Sonnet 5 $0.00009 $0.00375
Haiku 4.5 $0.00005 $0.00187

Measured 7d ago against content hash 4d86838a5a7b, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

crash-risk-audit 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 7d 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.

skills/quality/crash-risk-audit/SKILL.md · 147 lines

How it starts

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

Skill: Crash Risk Audit

Purpose

Detects force unwraps, force casts, force try, and other crash-prone Swift patterns that can cause unrecoverable crashes during App Store review, violating Guideline 2.1.

Apple Guideline

  • Primary: 2.1 — Performance: App Completeness (Crashes)
  • Related: 2.1
  • Reference: references/guidelines/2-performance.md

Real-World Rejection Cases

  • Case: Force unwrap crash on nil response — reviewer hit edge case with test data — rejected under 2.1 Source: Apple Developer Forums (multiple threads on crash-related rejections) Root cause: Force unwrap (!) causes EXC_BAD_INSTRUCTION crash at review time on edge-case data — reviewers use test accounts and synthetic data that may produce nil where the developer did not expect it

  • Case: Force cast as! crash when server returned unexpected type — reviewer triggered during review Source: Developer blogs Root cause: Casting without nil check produces unrecoverable crash — reviewers will encounter this on any data type mismatch between the server and the app's model layer

Trigger

Invoke on any iOS/macOS Swift project before App Store submission to identify high-risk crash patterns.

Inputs

Name Type Default Description
project_root path cwd iOS/macOS project root
shared_context object nil Pre-collected context from appstore-full-audit Phase 1

Actions

Phase 1: Context Collection

Skip this phase if shared_context is provided.

  1. Glob **/*.swift — collect all Swift source files.
  2. Glob **/*.m — collect Objective-C source files.

Phase 2: Checks

  1. Force unwrap Run multiple Grep patterns in **/*.swift to catch all force-unwrap variants:
    • [a-zA-Z0-9_]!\.[a-zA-Z] — force unwrap before property/method access (value!.property)
    • [a-zA-Z0-9_]! — force unwrap before space (let x = value! )
    • [a-zA-Z0-9_]!, — force unwrap in argument list (foo(value!, other))
    • [a-zA-Z0-9_]!\) — force unwrap inside parentheses (foo(value!))
    • [a-zA-Z0-9_]!\] — force unwrap before subscript (arr[value!])
    • [a-zA-Z0-9_]!$ — force unwrap at end of line (let x = dict["key"]!) Each match that is not in a test target or a SwiftUI #Preview block → 🔴 CRITICAL per occurrence. Replace with if let, guard let, or ?? fallback.

Read the full file on GitHub · 147 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. 7d ago First seen · 147 lines · 45 tokens per session scan A 4d86838a5a7b

Subscribe to this mod's changes

crash-risk-audit is a skill published in the GitHub repository cruisediary/apple-app-review-skills (16 stars, last pushed 4mo ago), licensed MIT. It adds 45 tokens to every session and 1,873 once invoked, about $0.0002 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-09-05.

Related

Other skills, from other repositories

argent-metro-debugger

Debug a JS runtime via CDP using argent debugger tools. Primary path is React Native via Metro (iOS / Android / Vega); a subset of the tools (debugger-connect, debugger-status, debugger-evaluate, debugger-log-registry) also drive a Chromium (CDP) app's renderer (an Electron app, or any Chromium browser exposing CDP)…

software-mansion/argent · 104 tokens

argent-react-native-optimization

Optimizes a React Native app by profiling first to find real bottlenecks, then sweeping for mechanical issues. Entry-point for all performance work. Use when the app feels slow, user asks to optimize, fix re-renders, reduce jank, or improve startup. Delegates to argent-react-native-profiler for measurement.

software-mansion/argent · 71 tokens

sentry-app-setup

Create and configure a Sentry internal integration so the assistant can manage issues, alerts, and releases under its own identity.

vellum-ai/vellum-assistant · 29 tokens

argent-native-profiler

Native profiling for CPU hotspots, UI hangs, memory issues. iOS via xctrace; Android via Perfetto. Use when diagnosing native-level performance issues.

software-mansion/argent · 37 tokens

review-pr

Review a pull request for conceptual fit, architecture impact, adversarial failure modes, security risk, docs impact, regression risk, test coverage, and merge readiness. Use when asked to review a PR, check whether a PR is safe to merge, decide if more tests are needed, perform adversarial or security review, or…

soniqo/speech-swift · 71 tokens

igf

CLI interface for igf (Grapefruit) dynamic instrumentation server. Use to enumerate Frida devices, list apps, run hooks, query logs, access device file systems, inspect classes, dump memory, and perform mobile app security analysis.

ChiChou/grapefruit · 51 tokens