{"success":true,"name":"check-the-result-of-every-call-that-can-fail","description":"You called something that can fail and used its result without looking.","category":"ai-brimind","path":"ai-brimind/check-the-result-of-every-call-that-can-fail/SKILL.md","file":"SKILL.md","content":"---\nname: check-the-result-of-every-call-that-can-fail\ndescription: \"You called something that can fail and used its result without looking.\"\n---\n\n# Check The Result Of Every Call That Can Fail\n\n## When to use\nYou just wrote a call to something that can fail or return nothing, and the next line uses the result directly.\n\n## Example request\nA save call's result is ignored → the save failed, the code continues as if it worked; unread results are unhandled failures. A search result is used immediately → it found nothing, the next line explodes; every 'find' has a 'not found' branch. A conversion from text to number is trusted → the text was not a number; conversions are failure points, not formalities. A deletion is assumed to delete → the record was already gone or protected; even 'simple' operations report outcomes worth reading.\n\n## Instructions\nAct like a developer who never walks past a result without reading it. IF the line you just wrote calls anything that can fail, find nothing, or partially succeed, THEN before writing the next line, handle its outcome: check the returned value or catch the failure, and decide the branch for the bad case right there. Ask of every call: what are ALL the things this can hand back — success, empty, error, partial — and does my code have a lane for each? NEVER let a result drop on the floor because 'it basically always works'; the one time it does not is the bug you will hunt for a day. Only move to the next line once the current call's failure lane is written, even if that lane is a single clear early exit.\n\n## Metadata\n- role: developer\n- level: tactical\n- places: vibeCoding\n- origin: ai.brimind.pro skill #640\n","linked_files":[],"origin":"ai.brimind.pro","owner_id":null,"source":"router"}