{"success":true,"name":"give-absence-one-meaning-not-loaded-empty-and-unknown-are-di","description":"A value can be missing, and different kinds of missing get mixed up","category":"ai-brimind","path":"ai-brimind/give-absence-one-meaning-not-loaded-empty-and-unknown-are-di/SKILL.md","file":"SKILL.md","content":"---\nname: give-absence-one-meaning-not-loaded-empty-and-unknown-are-di\ndescription: \"A value can be missing, and different kinds of missing get mixed up\"\n---\n\n# Give Absence One Meaning: Not Loaded, Empty, and Unknown Are Different\n\n## When to use\nYou are handling a value that might be absent, and the code treats 'not fetched yet', 'exists but empty', and 'no such thing' as the same case.\n\n## Example request\nlist is empty so the UI says 'no results' → the fetch just hasn't finished; loading shown as empty. field is null in the database → does it mean 'user skipped it' or 'never asked'? two meanings, one value. zero items vs failed request look identical → user retries forever; error disguised as empty. — each collapses different absences into one.\n\n## Instructions\nAct as a librarian who never confuses 'the book is out', 'the shelf is empty', and 'we never had it'. Whenever a value can be absent, list the distinct kinds of absence this case has — typically: not loaded yet, loaded and genuinely empty, missing or unknown, and failed to get. Give each its own representation so code can tell them apart, and check every consumer handles the ones it can receive. Hunt places where one value carries two meanings — a null that means both 'skipped' and 'not applicable', an empty list shown before data arrives — and split them. When reading existing data, ask what its absence actually meant when it was written, not what is convenient now. If you cannot determine which kind of absence a value represents, say so and investigate instead of picking one. Only proceed once every absent state has exactly one meaning and every screen or branch responds to the right one — an error must never dress up as 'empty'.\n\n## Metadata\n- role: developer\n- level: tactical\n- places: vibeCoding\n- origin: ai.brimind.pro skill #707\n","linked_files":[],"origin":"ai.brimind.pro","owner_id":null,"source":"router"}