py2exe is throwing erros due to open() not being able to work on files in a zip folder.
If i do a simple script
that includes
import past
(part of the future module) it will use a subpackage in lib2to3 called pgen2 which attempts to open a data file in lib2to3.
Is there a way to get this to work?
Cxfreeze works aroud this by you to unzip a module from library.zip and place it next to it which will get read instead, this works 100% fine.
Kind Regards
You can either change your code to use on of the zip libraries to open the file, or consider using http://www.py2exe.org/index.cgi/data_files
What are you suggesting exactly with the data files? I tried sucking them into a folder of the same name sitting next to the library.zip, however i still got my error. Modifying the source is a not going to really cut it in my case unfortunatley...
data_files should let you copy files into the created "dist", thus allowing them to be opened as regular files.
Without modification to anything? After using data files i have my library folder in a zip, then i have my module folder with my data files inside the "dist". This fails for the same reason, the module doesn't know where to find the data files.