Are you overlooking the effect of "defer"? AFAICT in your screenshot execution order is deterministic up to conditions, and the program terminates successfully (i.e. with empty "to-do list").
Anyway the hints are now available in-game, and I've also placed print() statements on separate lines (the spec, while being somewhat loose, doesn't allow both print() and lines specifications on the same line).