Oren Milman added the comment: just checked, and indeed on my Windows 10 the original code I posted here crashes the interpreter.
The patch in the PR undermines duck-typing, and that's why I added a comment there, stating I wasn't sure about the patch. an alternate solution would be to simply check whether the return value of pathname.replace('/', '\') is a str. do you think I would update the PR to do that? ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue31291> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com