Explain Python traceback code
Paste a Python traceback and Vibe explains what went wrong: which line in your code failed, how the program got there and what the error on the last line means.
Up to 1,500 characters (about 60 lines). Your code is sent to Unvibe and Anthropic to write the explanation. Don't paste keys or passwords. Common key formats are refused.
Vibe15 lines selected
Press Explain it for the sample, or paste your own code first.
What this Python traceback sample shows
- reading order
most recent call lastmeans the list runs from the first call at the top to the line that failed at the bottom:main()on line 19 calledorder_total(order)on line 16, and line 10 failed. The error itself is on the last line, so that's the place to start reading.- frames
- Each
File "...", line N, in nameentry is one call that was still running, with the line it had reached.in <module>is the script's top level.in <genexpr>is the generator expression insidesum(...), which Python runs as its own small function, so line 10 appears twice. - the error line
KeyError: 'qty'means the code asked a dictionary for a key it doesn't have, and names the key. The~and^marks under the code point at the part that failed,item["qty"]. In orders.json, the second order's item has"quantity": 3, not"qty".- chained errors
- When code catches one error and raises another, Python prints both tracebacks. A plain
raise ValueError(...)insideexcept KeyErrorputDuring handling of the above exception, another exception occurred:between them. Withraise ... from e, the line readThe above exception was the direct cause of the following exception:.
Good to know
- Run with Python 3.14.7 in a test folder, which is why the paths start with /home/sam/shop. On your computer they show where your own script is.
A1 25.0was printed before the traceback: the first order was fine, and output from before a crash stays on screen. The traceback goes to a different place, stderr: with2>/dev/nullonlyA1 25.0was left. The script ended with exit code 1.
Watch out: A quick fix can hide the problem instead of solving it. item.get("qty") only moved the crash, to TypeError: unsupported operand type(s) for *: 'int' and 'NoneType'. item.get("qty", 1) stopped the error but printed A2 4, counting 3 items as 1 without a word. Reading quantity when qty is missing printed the right A2 12.
Explain Python traceback code beside your editor
Unvibe is a free app for Mac and Windows. In the app there is no pasting: select code in any app and press Control+U (Ctrl+Alt+U on Windows).
Install on Mac
curl -fsSL https://unvibe.site/install.sh | bashPaste into Terminal. Unvibe isn't notarized by Apple yet, so this is the smooth path.
Or download the .dmg · Intel Mac build · SHA-256 checksums
Opening the .dmg the first time
- Open the .dmg and drag Unvibe to Applications.
- Open it once; macOS says it can't verify it. Click Done.

Real screen, macOS 15 - System Settings › Privacy & Security › Open Anyway. Confirm, then enter your Mac password. The button shows for about an hour after you try to open Unvibe.

Real screen, macOS 15
The Terminal line checks the download against the published SHA-256 and Unvibe's self-signed signature before it installs anything. More help with the first open