[issue25172] Unix-only crypt should not be present on Windows.

Srinivas Nyayapati report at bugs.python.org
Tue Aug 6 12:53:33 EDT 2019


Srinivas Nyayapati <shireenrao at gmail.com> added the comment:

What is the recommended way to check for platform in cpython? Is it using the sys module or os module? As for the error messages I couldn't think of anything better then what you suggested :). 

win32: raise ImportError("The crypt module is not supported on Windows")

not win32: raise ImportError("The required _crypt module was not built as part of CPython")

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue25172>
_______________________________________


More information about the Python-bugs-list mailing list