cron-env-isolation-guard

cron-env-isolation-guard is a skill for Claude Code, Codex from S3YED/appie-kit. It costs 45 tokens per session (669 once invoked), scanned A, original, MIT.

A troubleshooting guide for macOS launchd jobs, which run commands in the background, when their environment differs from an interactive terminal.

In plain words
What is it for?
Diagnosing cron or launchd failures, checking job exit codes and logs, handling missing API keys, repairing expired authentication, and preventing background hangs.
Why use it?
It explains why scheduled jobs may lose environment variables, stall while waiting for login input, or fail when plugins start.

Skill for Claude CodeCodex

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

Good fit Diagnosing cron or launchd failures, checking job exit codes and logs, handling missing API keys, repairing expired authentication, and preventing background hangs.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/s3yed/appie-kit/cron-env-isolation-guard
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 S3YED/appie-kit --skill cron-env-isolation-guard
Clone the repo
git clone --depth 1 https://github.com/S3YED/appie-kit

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 cron-env-isolation-guard

README.md
[![agentmods](https://agentmods.dev/badge/skills/s3yed/appie-kit/cron-env-isolation-guard/github.svg)](https://agentmods.dev/skills/s3yed/appie-kit/cron-env-isolation-guard)
Your own site
<a href="https://agentmods.dev/skills/s3yed/appie-kit/cron-env-isolation-guard"><img src="https://agentmods.dev/badge/skills/s3yed/appie-kit/cron-env-isolation-guard/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 cron-env-isolation-guard

Your own site · 80×15
<a href="https://agentmods.dev/skills/s3yed/appie-kit/cron-env-isolation-guard"><img src="https://agentmods.dev/badge/skills/s3yed/appie-kit/cron-env-isolation-guard.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 669 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.00669
Opus 5 $0.00023 $0.00334
Sonnet 5 $0.00009 $0.00134
Haiku 4.5 $0.00005 $0.00067

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

Security

Grade A, and why

cron-env-isolation-guard 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 9d 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/devops/cron-env-isolation-guard/SKILL.md · 55 lines

How it starts

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

Cron Env Isolation Guard

Why this exists

macOS launchd strips most shell environment from launched jobs. Variables available in an interactive terminal are NOT inherited. Common silent failures:

  • API key env var missing → CLI crashes immediately
  • OAuth keyring prompt has no TTY → deadlock
  • MCP plugins init on claude startup → hang → SIGKILL after watchdog timeout

Diagnostic checklist (run in order)

  1. Check exit code: launchctl list | grep <label> — column 2 is last exit code. -1 / 1 = crash; -15 = SIGTERM (watchdog?).
  2. Check log size: if stdout log = 0 or ~90 bytes, job started but didn't produce output → silent crash or early hang.
  3. Read the log: check stderr path from the plist. Look for:
    • no TTY available for keyring file backend password prompt → add the keyring password to plist EnvironmentVariables.
    • invalid_grant / Bad Request → OAuth token expired; need interactive re-auth.
    • aes.KeyUnwrap(): integrity check failed → encrypted token corrupted; need re-auth.
    • Python traceback / CLI crash → missing API key in env.
    • MCP plugin startup messages followed by silence + SIGKILL → add --no-mcp to claude -p invocation.
  4. Read the plist: confirm which EnvironmentVariables are set. Compare against what the script needs interactively.
  5. Run the script manually with the same PATH the plist specifies: PATH=<plist-PATH> <command>. Compare output.

Common fixes

Symptom Fix
Keyring/password prompt has no TTY Add password env var to plist EnvironmentVariables dict
OAuth expired (invalid_grant) Re-auth interactively, then reload launchd job
CLI crash (no API key) Add API key to plist env
claude -p hangs on MCP init Add --no-mcp flag to the claude invocation
Any env var missing Add to plist EnvironmentVariables OR source a .env file at script start

Applying plist fixes

# Edit the plist to add env vars, then reload:
launchctl unload ~/Library/LaunchAgents/<label>.plist
launchctl load ~/Library/LaunchAgents/<label>.plist

# Verify:
launchctl list | grep <label>

Read the full file on GitHub · 55 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. 9d ago First seen · 55 lines · 45 tokens per session scan A 563b61f41438

Subscribe to this mod's changes

cron-env-isolation-guard is a skill published in the GitHub repository S3YED/appie-kit (9 stars, last pushed 17d ago), licensed MIT. It adds 45 tokens to every session and 669 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-03.