techmefr/mentis/dotnet-no-swallow-exceptions

Claude Code and agent skill by techmefr/mentis

Trust tier 3
  • community
Source check pending

Checking that the SKILL.md file is still in the repository.

Use when writing or reviewing a catch block: never an empty catch {} or a catch (Exception) {} with no log or rethrow — it reports success having done nothing, and leaves no log entry when the incident happened.

Install

npx vskill@latest install techmefr/mentis/dotnet-no-swallow-exceptions

SKILL.md

The same SKILL.md was published earlier as techmefr/mentis/dotnet-no-swallow-exceptions.

dotnet-no-swallow-exceptions

Narrow trigger extracted from skills/dotnet-conventions §5.5, so a catch block routes here directly instead of only through the whole .NET block.

When

Writing or reviewing any try/catch — a boundary converting a library exception, a background operation, a fire-and-forget Task.

Steps

  1. An empty `catch {}` or a `catch (Exception) {}` with no log or rethrow swallows a real bug.

Never a silent catch.

  1. The visible consequence is a request that reports success having done nothing. The invisible

one is that the log has no entry at the moment the incident actually happened.

  1. A `Task` never awaited or stored is the same failure in fire-and-forget clothes. It silently

swallows its exceptions unless something explicitly observes them.

Output / checkpoint

Every catch in the diff either logs with the original exception, rethrows (bare throw or ExceptionDispatchInfo to preserve the stack), or does something concrete — never empty, never log-only-then-continue on a path that should have failed.

Guardrails

  • Catching by type, not by message, is what survives a refactor — a broad catch (Exception) that

also swallows a genuine bug in the handling code itself is the specific failure this rule targets.

  • A fire-and-forget Task needs an explicit continuation or a supervised background-task pattern to

observe its exceptions — skills/dotnet-conventions §1 covers the async-specific version.

Origin

No external source: this is skills/dotnet-conventions §5.5 (and the fire-and-forget note in §1) extracted to its own trigger. Written 2026-09-09, same restructuring pilot as laravel-no-db-enums.

Security

  • Security scanPassed, 90 of 100Pattern checks on the skill's files.
  • Model reviewPassed

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

7-day trend score
5

Not refreshed yet.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/techmefr/mentis/dotnet-no-swallow-exceptions/badge)](https://verified-skill.com/skills/techmefr/mentis/dotnet-no-swallow-exceptions)

Something wrong with this skill or its page? Tell us.