Hacker News new | ask | show | jobs
by talex5 4750 days ago
The "Permission Denied" message you see here is from your shell, not Python.

But note the test isn't about whether you can open the file successfully, but about detecting writes to an open file failing (e.g. because the disk becomes full during writing).

1 comments

His example focused on the program return code which in this case is correctly 1