Vedran Čačić <ved...@gmail.com> added the comment: If I understand correctly, those are _private methods_ (names start with underscore). In such cases, asserts can be completely fine, since the library writer controls the situations where the method is called. If it is never called with _UNKNOWN argument, assert is just that, assertion that it is so. (It would be different if it were a public method, since the library writer doesn't know it will never be called with _UNKNOWN.)
---------- nosy: +veky _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue42060> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com