helix.mcp: Skill for Claude Code

.copilot/skills/cancellation-vs-timeout/SKILL.md

cancellation-vs-timeout is a skill for Claude Code, Codex from lewing/helix.mcp. It costs 0 tokens per session (352 once invoked), scanned A, original, MIT.

A skill guide for telling apart an HTTP request timeout from deliberate cancellation in .NET. Both can raise the same `TaskCanceledException` error.

In plain words
What is it for?
Use it when writing .NET code that catches cancelled HTTP requests and needs different handling or messages for timeouts and cancellations.
Why use it?
It prevents a timeout from being reported as user cancellation, especially when no cancellation token was supplied.

Skill for Claude CodeCodex

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

This is lewing/helix.mcp's own configuration. It tells Claude Code and Codex how to work on helix.mcp 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 helix.mcp configures →

Reuse

Borrowing it

Nothing to install: this file belongs to lewing/helix.mcp. 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/lewing/helix.mcp/main/.copilot/skills/cancellation-vs-timeout/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/lewing/helix.mcp

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 cancellation-vs-timeout

README.md
[![agentmods](https://agentmods.dev/badge/skills/lewing/helix.mcp/cancellation-vs-timeout/github.svg)](https://agentmods.dev/skills/lewing/helix.mcp/cancellation-vs-timeout)
Your own site
<a href="https://agentmods.dev/skills/lewing/helix.mcp/cancellation-vs-timeout"><img src="https://agentmods.dev/badge/skills/lewing/helix.mcp/cancellation-vs-timeout/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 cancellation-vs-timeout

Your own site · 80×15
<a href="https://agentmods.dev/skills/lewing/helix.mcp/cancellation-vs-timeout"><img src="https://agentmods.dev/badge/skills/lewing/helix.mcp/cancellation-vs-timeout.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 352 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.00000 $0.00352
Opus 5 $0.00000 $0.00176
Sonnet 5 $0.00000 $0.00070
Haiku 4.5 $0.00000 $0.00035

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

Security

Grade A, and why

cancellation-vs-timeout 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.

.copilot/skills/cancellation-vs-timeout/SKILL.md · 43 lines

What it actually says

Skill: Distinguishing HTTP Timeout from Cancellation in .NET

Confidence: low Source: earned

Problem

When wrapping async HTTP calls with CancellationToken support, both HTTP timeouts and intentional cancellation throw TaskCanceledException. You need to distinguish them to provide different error messages (e.g., "request timed out" vs. letting cancellation propagate).

Wrong Pattern

catch (TaskCanceledException ex) when (ex.CancellationToken == cancellationToken)
{
    throw; // Intended as "real cancellation"
}
catch (TaskCanceledException ex)
{
    throw new MyException("Request timed out.", ex); // Intended as timeout
}

Why it fails: When cancellationToken is CancellationToken.None (from = default) and the TaskCanceledException is constructed without a token (also CancellationToken.None), the equality check matches — treating a timeout as cancellation.

Correct Pattern

catch (TaskCanceledException) when (cancellationToken.IsCancellationRequested)
{
    throw; // Real cancellation — the caller's token was triggered
}
catch (TaskCanceledException ex)
{
    throw new MyException("Request timed out.", ex); // HTTP timeout
}

Why it works: IsCancellationRequested checks whether the caller's token was actually signaled. If it wasn't, the TaskCanceledException must have come from an HTTP timeout. This is semantically correct regardless of how the exception was constructed.

When to Apply

Any time you're catching TaskCanceledException in a method with a CancellationToken cancellationToken = default parameter and need to distinguish timeout from cancellation.

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 · 43 lines · 0 tokens per session scan A 12d3a770a9ca

Subscribe to this mod's changes

cancellation-vs-timeout is a skill published in the GitHub repository lewing/helix.mcp (4 stars, last pushed today), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 352 tokens. 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-31.

Related

Other skills, from other repositories

debug

Systematic 4-phase debugging with escalation protocol. Use when saying "debug", "investigate bug", "find root cause", "why is this failing", or "fix this bug".

anton-abyzov/specweave · 38 tokens

argot-refresh

Refresh Argot's committed fit snapshot safely — first diagnose why maintenance is recommended, re-audit corpus scope and structural path changes, review stale mutes and policy entries with the user, then fit locally, verify, and prepare the reviewed .argot/ update. Use when argot status, argot check, MCP, or CI…

get-tmonier/argot · 136 tokens

docverity

Check whether a project's documentation still matches its code, and report stale or wrong claims with suggested fixes. Use this after editing, renaming, moving, or deleting source files, CLI flags, environment variables, or functions, to catch docs you may have just made inaccurate; when the user asks whether the…

deveshagarwal/docverity · 84 tokens

code_explorer

Explores the repository to locate primary source files, coupled UI components, and test files for bug reports or feature requests.

google-gemini/gemini-cli · 28 tokens

session-investigator

Investigate fast-agent session and history files to diagnose issues. Use when a session ended unexpectedly, when debugging tool loops, when correlating sub-agent traces with main sessions, or when analyzing conversation flow and timing. Covers session.json metadata, history JSON format, message structure, tool…

evalstate/fast-agent · 68 tokens

smiles-validation

Strict SMILES validation, structural comparison, and modification verification. Catches invalid LLM-generated molecules.

synthetic-sciences/openscience · 24 tokens