Skip to content
Skills Library
Programming · Analysis

stack-trace-reading

/stack-trace-reading

Read a stack trace to find the cause frame instead of stopping at the symptom on top. Use when an exception, panic, or error dump lands and you need to locate the line that is actually wrong.

Repository
AI-SKILLS ↗
Licence
MIT
Last repository change
05.09.2026

Assessment and security

90/ 100Class: good
Format25 / 25
Frontmatter with name and description, valid name, description up to 1,024 characters, name matching the folder.
Discoverability25 / 25
Description explains when to use the skill, has a reasonable length and uses third person.
Content25 / 35
At least 150 words and at most 500 lines, headings, step lists, examples or code.
Hygiene15 / 15
No placeholders such as TODO, no Windows paths, with a licence.
Riskno signals detected in the scan
Files in this package
1
Scripts
0
HTML comments
0
URLs in SKILL.md
0
Deprecation

No signals detected. Repository changed on 05.09.2026, without references to retired models or APIs.

Licence

MIT, open: use and modify while retaining author attribution.

What it does and when to use it

Read a stack trace to find the cause frame instead of stopping at the symptom on top. Use when an exception, panic, or error dump lands and you need to locate the line that is actually wrong.

Original author description

Read a stack trace to find the cause frame instead of stopping at the symptom on top. Use when an exception, panic, or error dump lands and you need to locate the line that is actually wrong.

How it works

  1. Method
  2. Signals
  3. Boundaries
Original SKILL.md headings · 50 lines, 453 words
SKILL.md preview
---
name: stack-trace-reading
description: Read a stack trace to find the cause frame instead of stopping at the symptom on top. Use when an exception, panic, or error dump lands and you need to locate the line that is actually wrong.
---

# Stack trace reading

A stack trace is a story told backwards. The top frame is where the program
noticed the problem, which is rarely where the problem started. The reflex
to fix the topmost line patches a symptom and leaves the cause. Read the
trace as a map from where you are to your own code that put you there.

## Method

1. **Read the exception type and message first, together.** `NullPointer`,
   `KeyError: 'user_id'`, `ECONNREFUSED 127.0.0.1:5432`: the type says what
   rule broke and the message says on what value. That pair alone often
   names the cause before you look at a single frame.
2. **Find the boundary between your code and the library.** Traces run
   deepest-call-on-top in most runtimes (Java, JS, Ruby) and
   deepest-on-bottom in Python. Scan for the first frame in a path you
   own, next to the framework or standard-library frames. The bug usually
   sits at that seam, where your data entered someone else's code.
3. **Separate cause frames from symptom frames.** The top frame is where it
   threw. The frame that passed the bad value is a few steps down, in your
   code. A null dereferenced in a library means your caller handed it null;
   walk down until the arguments become yours, and read what you passed.
4. **Follow "Caused by" and "During handling" to the original.** Wrapped
   exceptions chain: Java prints `Caused by:` deeper, Python prints "The
   above exception was the direct cause". The root cause is the last link
   in that chain, not the first one printed. Read to the bottom of the chain
   before forming a hypothesis.
5. **Map frames to versions with line numbers.** A frame is `file:line` for
   a reason. Open that exact line at the committed revision, not `main`.
   Minified or optimized stacks need a source map or symbol file first, or
   the line numbers point at nothing real.
6. **Discard async and framework noise deliberately.** Event loops,
   thread pools, and promise machinery fill traces with frames you did not
   write and cannot fix. Collapse them mentally and keep only the frames in
   your packages: that shortened trace is the one to reason about.

## Signals

- Can you name the exact line in your own code that created the bad value?
- Did you read to the end of the "Caused by" chain, not just the first line?
- Does the frame you plan to fix hold the cause, or just where it surfaced?

## Boundaries

Stack overflow, memory corruption, and optimized release builds produce
traces that lie: inlined frames vanish, tail calls collapse, and the top
frame may be a victim of earlier damage. There, trust a core dump or a
sanitizer over the printed trace, and see the core-dumps skill.

Versions

The database has no other skills named stack-trace-reading.

Database snapshot: 13.11.2026 · package version 95d544107251 (SHA-256 digest of the entire package)

Downloads in the last 30 days: 0 · ranking

Report a problem with this skill: harmful content, incorrect descriptions or an author’s removal request.

Similar skills

  • 90error-reading
    Use when the user pastes any error output, stack trace, log, or failure message — structured interpretation before diagnosis
  • 100stack-trace-analysis
    Reads stack traces and crash reports across Java/Kotlin, Python, JavaScript/Node, Go, .NET, Rust, and Swift/Objective-C - finds the first relevant frame, follows chained causes, recognises common failure signatures, and symbolicates native and minified traces. Use when given an…
  • 100debugging
    A systematic method for finding the root cause of a bug, crash, error, or wrong output — reproduce, isolate, hypothesize, test, fix. Use when users report something broken, an exception/stack trace, flaky behavior, or 'why doesn't this work'. Triggers on mentions of bug, error,…
  • 100debug-issue
    Systematic debugging workflow for any code error, crash, test failure, or unexpected behavior. Use this skill whenever a user mentions an error, bug, exception, crash, test failure, or says something "isn't working", "is broken", "keeps failing", or "isn't behaving as expected"…
  • 100debug-triage
    Use when triaging a pasted error, stack trace, or terminal transcript. Activates on "debug this", "fix this", "why is this broken", or when a user pastes red terminal output. Produces a tight cause-fix-test report, not a lecture.
  • 100debug-detective
    Find the root cause of a bug, crash, error message or failing test, then fix it. Use when the user says "this is broken", "why does this fail", "I get this error", "the test is failing", "it worked yesterday", or pastes a stack trace.

Feedback and reports

Your message goes to Bartosz Sokoliński. An email address is needed only for a reply. See the privacy policy.