New submission from gaborjbernat <gaborjber...@gmail.com>: ❯ py -c "from pathlib import Path; Path('http://w.org').exists()" Traceback (most recent call last): File "<string>", line 1, in <module> File "C:\Python39\lib\pathlib.py", line 1407, in exists self.stat() File "C:\Python39\lib\pathlib.py", line 1221, in stat return self._accessor.stat(self) OSError: [WinError 123] The filename, directory name, or volume label syntax is incorrect: 'http:\\w.org'
The above code returns correctly False on UNIX systems. ---------- components: Windows messages: 384569 nosy: gaborjbernat, paul.moore, steve.dower, tim.golden, zach.ware priority: normal severity: normal status: open title: pathlib.exists on Windows raises an exception on URL like/bad input versions: Python 3.10, Python 3.6, Python 3.7, Python 3.8, Python 3.9 _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue42855> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com