Closed programingfrik closed 8 months ago
Thanks for the report.
The issue is that IronPython 3.4 uses the standard library from Python 3.4 and os.PathLike
was only added in Python 3.6. This means the current pathlib
classes don't implement os.PathLike
. Assuming it's not too complicated, might be worth backporting from 3.6 to our version of pathlib
...
Thanks for your fast response. I appreciate very much this project.
Description
Open a file using a WindowsPath object as its path fails on ironpython3. On cpython3 it works.
Steps to Reproduce
Expected behavior:
The obf object should be created. A file object pointing to "c:\some\existing\file.txt". I should be able to use that file object as any other file object to read or write the file.
Writing this same lines of code on cpython3 (version 3.9.10) works as expected produces the obf file object.
Actual behavior:
The last line raises an exeption "TypeError: expected str, bytes or os.PathLike object, not WindowsPath"
To make it work one has to use "open(str(fichero))".
Version Information