3

I am trying to create a simple exe through nuitka so that I can run it on my laptop without Python needing to be installed.

I am on windows 10 and using Anaconda Python 3. I typed in:

nuitka --recurse-all hello.py

However, I keep getting the following error message:

C:\Users\Bain3>Nuitka --exe 123.py
Nuitka:WARNING:Not recursing to 'selenium' (C:\Users\Bain3\Anaconda3\Lib\site-packages\selenium), please specify --recurse-none (do not warn), --recurse-all (recurse to all), --recurse-not-to=selenium (ignore it), --recurse-to=selenium (recurse to it) to change.
Nuitka:WARNING:Not recursing to 'selenium.webdriver.support.ui' (C:\Users\Bain3\Anaconda3\Lib\site-packages\selenium\webdriver\support\ui.py), please specify --recurse-none (do not warn), --recurse-all (recurse to all), --recurse-not-to=selenium.webdriver.support.ui (ignore it), --recurse-to=selenium.webdriver.support.ui (recurse to it) to change.
Nuitka:WARNING:Not recursing to 'selenium.webdriver.support' (C:\Users\Bain3\Anaconda3\Lib\site-packages\selenium\webdriver\support), please specify --recurse-none (do not warn), --recurse-all (recurse to all), --recurse-not-to=selenium.webdriver.support (ignore it), --recurse-to=selenium.webdriver.support (recurse to it) to change.
Nuitka:WARNING:Not recursing to 'selenium.webdriver.common.by' (C:\Users\Bain3\Anaconda3\Lib\site-packages\selenium\webdriver\common\by.py), please specify --recurse-none (do not warn), --recurse-all (recurse to all), --recurse-not-to=selenium.webdriver.common.by (ignore it), --recurse-to=selenium.webdriver.common.by (recurse to it) to change.
Nuitka:WARNING:Not recursing to 'requests' (C:\Users\Bain3\Anaconda3\Lib\site-packages\requests), please specify --recurse-none (do not warn), --recurse-all (recurse to all), --recurse-not-to=requests (ignore it), --recurse-to=requests (recurse to it) to change.
Nuitka:WARNING:Not recursing to 'selenium.common.exceptions' (C:\Users\Bain3\Anaconda3\Lib\site-packages\selenium\common\exceptions.py), please specify --recurse-none (do not warn), --recurse-all (recurse to all), --recurse-not-to=selenium.common.exceptions (ignore it), --recurse-to=selenium.common.exceptions (recurse to it) to change.
Nuitka:WARNING:Not recursing to 'retrying' (C:\Users\Bain3\Anaconda3\Lib\site-packages\retrying.py), please specify --recurse-none (do not warn), --recurse-all (recurse to all), --recurse-not-to=retrying (ignore it), --recurse-to=retrying (recurse to it) to change.
Error, cannot find "gendef.exe" which is required though.

I have reinstalled Python and used 2.7 however this did not seem to help…

**FURTHER TESTING IN VIRTUAL MACHINE....*

UPDATE. They STATE they support 3.6, but they actually don't. It says DOES NOT SUPPORT 3.6 in console yet on their webiste they say they support it. Bit misleading...

Tetora
  • 433
  • 8
  • 25
  • 1
    nuitka --standalone --portable --remove-output --recurse-all --python-version=3.4 hello_world.py ? –  Oct 30 '17 at 01:31
  • same issue sadly. – Tetora Oct 30 '17 at 01:33
  • Download cython and try this instead. hello.py --embed –  Oct 30 '17 at 01:43
  • gcc hello.c -IC:\Users\ACA\1\ -LC:\Users\ACA\Anaconda3\python3.dll -lC:\Users\ACA\Anaconda3\ -o hello1.py –  Oct 30 '17 at 01:47
  • @Wman Hmmm.... does not recognise – Tetora Oct 30 '17 at 01:48
  • Good point. I might look into this. –  Oct 30 '17 at 02:11
  • 1
    Have you seen https://stackoverflow.com/questions/47007017/nuitka-not-compiling-an-exe-with-nuitka-recurse-all-hello-py-error and https://stackoverflow.com/questions/34841288/cant-compile-python-using-nuitka ? None of the answers look especially helpful but it's possible that there's something to be learned. – DavidW Oct 30 '17 at 08:49
  • @DavidW Yes, unfortunately that question wasn't resolved. Tried: nuitka --recurse-all 123.py --recurse-to=urllib as well as reinstalling python 2 and 3. I'm right now testing it out on my laptop with no libaries installed and python 2 to see if it makes any difference – Tetora Oct 30 '17 at 08:52
  • @DavidW https://stackoverflow.com/questions/35550788/problems-on-creation-of-executable-file-from-python-with-nuitka had an identical issue as well. I've contacted github author but am not holding my breath as this issue is years old and not resolved. – Tetora Oct 30 '17 at 10:17
  • I'll look into C#. A sad day indeed. Why design an application that doesn't work. RIP – Tetora Oct 30 '17 at 10:25
  • I can advice you this: 1) find reason why it doesn't work (try compile exe without importing selenium, try standard CPython, etc. - until success) 2) create minimal possible reproducible example and provide it here (others can only guess without being able to test ideas on your example) 3) create issue [here](http://bugs.nuitka.net/), again, attaching minimal reproducible example – Mikhail Gerasimov Oct 30 '17 at 11:01
  • @MikhailGerasimov I believe the issues are: '--recurse-directory'. and "gendef.exe" related errors. Obviously in relation to MingW and Anaconda Python directories getting confused at which location. I've literally spent all day trying to get this to work. Cython was okay, I got that working. But 150mb/executable was insane. I'll post there nonetheless. – Tetora Oct 30 '17 at 11:05

0 Answers0