promptdojo_

AI wrote a function that reads a config file and falls back to a default if the file is missing. Trouble is, the function calls read_text first and then has nothing to catch the FileNotFoundError. The script crashes when the path doesn't exist.

Add an if path.exists(): guard so the function returns "default config" when the file is missing and the file's contents when it exists.

The break is on line 4 — but read the whole snippet first.

this step needs the editor

on desktop today; in the app (coming soon). save your spot and we'll bring you back here when you're ready.

open this same url on a laptop to keep going today.