Bare asserts can be quite difficult for users to understand as they throw an assertion error with minimal user information.
Instead it would be better to check for file existance and throw an appropriate error type (IOError for files being missing maybe?) with a human readable error message.
Bare asserts can be quite difficult for users to understand as they throw an assertion error with minimal user information.
Instead it would be better to check for file existance and throw an appropriate error type (IOError for files being missing maybe?) with a human readable error message.