question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

I can't compile my project by pyinstaller

See original GitHub issue

I have a script with code:

from mimesis import Personal
person = Personal('en')
person.full_name()

and it works well, but after compiling this code to .exe via pyinstaller I have an error FileNotFoundError: [Errno 2] No such file or directory: ‘B:\_MEI131682\mimesis\data/es\personal.json’ [20624] Failed to execute script myproject So, I think that problem in path (data/es\\personal). What ways of solving this problem can you recommend?

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:6 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
dumpropcommented, Jan 19, 2018

But I compiled it 😄 I added mimesis data to working dir and executed pyinstaller --onefile --add-data mimesis;mimesis myscript.py and now all works fine 😃

2reactions
lk-geimfaricommented, Jan 19, 2018

@h0n3yc4k3 I have fixed this issue (see #376). Now, this should work fine. Can you, please, uninstall an old version (v1.0.4) of mimesis and install latest (v1.0.5) and confirm that issue was fixed. Thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

When Things Go Wrong — PyInstaller 5.7.0 documentation
Build -Time Python Errors¶ ... PyInstaller sometimes terminates by raising a Python exception. In most cases the reason is clear from the exception...
Read more >
Error while compiling python project with pyinstaller #2162
Here is my spec file. See under datas property and ensure that path is correct since directories under venv are OS specific. #...
Read more >
I cant compile my .py to an .exe(missing .dll files)
Try pyinstaller filename.py -w or pyinstaller filename.py . Remove --onefile ...
Read more >
Using PyInstaller to Easily Distribute Python Applications
How PyInstaller can simplify application distribution; How to use PyInstaller on your own projects; How to debug PyInstaller errors; What PyInstaller can't do....
Read more >
Python and PyInstaller — Introduction and Troubleshooting
This is because even though PyInstaller tries to look for all the files required by your script, there may be binary or file...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found