Search code examples
pythonpyinstaller

expected str, bytes or os.PathLike object, not BytesIO


So, I'm trying to make a .exe from a .py with pyinstaller. It compiles without raising any error but I get an error from running the .exe :

Failed to execute script 'Editor' due to unhandled exception:
expected str, bytes or os.PathLike object, not BytesIO

and the worst thing is that it says

Failed to obtain/convert traceback!

under it so I don't know where to search.

I'm already using pyinstaller for another project with the same coding environment (VSC) and it works fine.

I'm using pygame and numpy, but I also did in the other project I mentionned.

I tried some solution found on SO (ex: An error for generating an exe file using pyinstaller - typeerror: expected str, bytes or os.PathLike object, not NoneType) but it wasn't the same error message anyway.

I am currently trying to replicate the error.


Solution

  • I solved it by updating my libraries...