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.

Compiling easy install entry points doesn't result in anything useful

See original GitHub issue
  • Nuitka version, full Python version and Platform (Windows, OSX, Linux …)

    python -m nuitka --version

0.6.16.2
Python: 3.9.6 (default, Jun 30 2021, 10:22:16)
Executable: /home/finkel/work_self/Flexget/bin/python
OS: Linux
Arch: x86_64
  • How did you install Nuitka and Python

I’ve install nuitka in pip and python from my distribution, working inside venv

  • The specific PyPI names and versions

    python -m pip freeze

aniso8601==9.0.1
APScheduler==3.7.0
attrs==20.3.0
babelfish==0.5.5
beautifulsoup4==4.9.3
Brotli==1.0.9
certifi==2020.12.5
chardet==4.0.0
cheroot==8.5.2
CherryPy==18.6.0
click==7.1.2
colorama==0.4.4
colorclass==2.2.0
deluge-client==1.9.0
feedparser==6.0.8
Flask==1.1.2
Flask-Compress==1.10.1
Flask-Cors==3.0.10
Flask-Login==0.5.0
Flask-RESTful==0.3.9
flask-restx==0.4.0
-e git+git@github.com:Flexget/Flexget.git@ed41e678ac5e5e700cde7c2345b7004d2c1e03ef#egg=FlexGet
greenlet==1.0.0
guessit==3.2.0
html5lib==1.1
idna==2.10
importlib-metadata==4.6.0
itsdangerous==1.1.0
jaraco.classes==3.2.1
jaraco.collections==3.3.0
jaraco.functools==3.3.0
jaraco.text==3.5.0
Jinja2==3.0.1
jsonschema==3.2.0
loguru==0.5.3
MarkupSafe==2.0.0
more-itertools==8.8.0
Nuitka==0.6.16.2
plumbum==1.7.0
portend==2.7.1
progressbar==2.5
psutil==5.8.0
pynzb==0.1.0
pyparsing==2.4.7
pyrsistent==0.17.3
PyRSS2Gen==1.1
python-dateutil==2.8.1
pytz==2021.1
PyYAML==5.4.1
rebulk==3.0.1
requests==2.25.1
rpyc==5.0.1
SCons==4.1.0.post1
sgmllib3k==1.0.0
six==1.15.0
soupsieve==2.2.1
SQLAlchemy==1.4.20
tempora==4.0.2
terminaltables==3.1.0
typing-extensions==3.10.0.0
tzlocal==2.1
urllib3==1.26.4
webencodings==0.5.1
Werkzeug==1.0.1
zc.lockfile==2.0
zipp==3.4.1
zxcvbn-python==4.4.24
  • Many times when you get an error from Nuitka, your setup may be special

works with following output:

Nuitka-Options:INFO: Used command line options: --run some.py
Nuitka:INFO: Starting Python compilation with Nuitka '0.6.16' on Python '3.9' commercial None.
Nuitka:INFO: Completed Python level compilation and optimization.
Nuitka:INFO: Generating source code for C backend compiler.
Nuitka:INFO: Running data composer tool for optimal constant value handling.
Nuitka:INFO: Running C level backend compilation via Scons.
Nuitka-Scons:INFO: Backend C compiler: gcc (gcc).
Nuitka-Scons:INFO: Compiled 12 C files using ccache.
Nuitka-Scons:INFO: Cached C files (using ccache) with result 'disabled': 1
Nuitka-Scons:INFO: Cached C files (using ccache) with result 'cache miss': 11
Nuitka:INFO: Keeping build directory 'some.build'.
Nuitka:INFO: Successfully created 'some.bin'.
Nuitka:INFO: Launching 'some.bin'.
hello world

I’mtrying to build flexget with nuitka3-run --standalone --onefile --linux-onefile-icon=./256.png --plugin-enable=numpy --plugin-enable=pylint-warnings bin/flexget execute and getting following output

Nuitka-Options:INFO: Used command line options: --run --standalone --onefile --linux-onefile-icon=./256.png --plugin-enable=numpy --plugin-enable=pylint-warnings bin/flexget
Nuitka:INFO: Starting Python compilation with Nuitka '0.6.16' on Python '3.9' commercial None.
Nuitka-Plugins:INFO: implicit-imports: Implicit dependencies of module 'tkinter' added '_tkinter'.                                                                                                                
Nuitka-Plugins:INFO: implicit-imports: Implicit dependencies of module 'socket' added '_socket'.
Nuitka-Plugins:INFO: implicit-imports: Implicit dependencies of module 'ctypes' added '_ctypes'.                                                                                                                  
Nuitka-Plugins:INFO: implicit-imports: Implicit dependencies of module 'numpy' added 'numpy.compat,numpy.lib,numpy.linalg,numpy.fft,numpy.polynomial,numpy.random,numpy.random._bounded_integers,numpy.random._common,numpy.random._generator,numpy.random._mt19937,numpy.random._pcg64,numpy.random._philox,numpy.random._sfc64,numpy.random.bit_generator,numpy.random.mtrand,numpy.ctypeslib,numpy.ma,numpy.matrixlib'.          
Nuitka-Plugins:INFO: implicit-imports: Implicit dependencies of module 'pycparser.c_parser' added 'pycparser.yacctab,pycparser.lextab'.
Nuitka-Plugins:INFO: implicit-imports: Implicit dependencies of module 'scipy._lib' added 'scipy._lib.messagestream'.                                                                                             
Nuitka-Plugins:INFO: implicit-imports: Implicit dependencies of module 'numpy.random' added 'numpy.random._bounded_integers,numpy.random._common,numpy.random._generator,numpy.random._mt19937,numpy.random._pcg64,numpy.random._philox,numpy.random._sfc64,numpy.random.bit_generator,numpy.random.mtrand'.                                                                                                                        
Nuitka-Plugins:INFO: implicit-imports: Implicit dependencies of module 'numpy.core' added 'numpy.core._dtype_ctypes,numpy.core._multiarray_tests'.                                                                
Nuitka:INFO: Completed Python level compilation and optimization.                                                                                                                                                 
Nuitka:INFO: Generating source code for C backend compiler.                                                                                                                                                       
Nuitka:INFO: Running data composer tool for optimal constant value handling.                                                                                                                                      
Nuitka:INFO: Running C level backend compilation via Scons.
Nuitka-Scons:INFO: Backend C compiler: gcc (gcc).
Nuitka-Scons:INFO: Compiled 160 C files using ccache.                                                                                                                                                             
Nuitka-Scons:INFO: Cached C files (using ccache) with result 'disabled': 1
Nuitka-Scons:INFO: Cached C files (using ccache) with result 'cache hit': 159
Nuitka-Plugins:INFO: data-files: Included data file 'lib2to3/Grammar3.9.6.final.0.pickle' due to package data for 'lib2to3.pgen2'.
Nuitka-Plugins:INFO: data-files: Included data file 'lib2to3/PatternGrammar3.9.6.final.0.pickle' due to package data for 'lib2to3.pgen2'.
Nuitka-Postprocessing:INFO: Creating single file from dist folder, this may take a while.
Nuitka-Postprocessing:INFO: Completed onefile creation.
Nuitka:INFO: Keeping dist folder 'flexget.dist' for inspection, no need to use it.
Nuitka:INFO: Keeping build directory 'flexget.build'.
Nuitka:INFO: Successfully created 'flexget.bin'.
Nuitka:INFO: Launching 'flexget.bin'.
Traceback (most recent call last):
File "/tmp/finkel/.mount_flexgeAVwdY2/flexget", line 33, in <module>
File "/tmp/finkel/.mount_flexgeAVwdY2/flexget", line 25, in importlib_load_entry_point
File "/tmp/finkel/.mount_flexgeAVwdY2/importlib/metadata.py", line 77, in load
File "importlib.py", line 127, in import_module
File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
File "<frozen importlib._bootstrap>", line 986, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 680, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 850, in exec_module
File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
File "/home/finkel/work_self/Flexget/flexget/__init__.py", line 10, in <module>
from flexget import log  # noqa
File "/home/finkel/work_self/Flexget/flexget/log.py", line 14, in <module>
import loguru
ModuleNotFoundError: No module named 'loguru'
  • In your issue the options used

    Ideally use the project feature, so options and example code go alone

    Nuitka Options in the code

  • Note if this is a regression

    If it used to work in an earlier version of Nuitka, please note what you know about that.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:17 (13 by maintainers)

github_iconTop GitHub Comments

3reactions
kayhayencommented, Dec 3, 2021

This is part of the 0.6.18 release.

0reactions
kayhayencommented, Nov 10, 2021

This is on the develop branch now and will be part of the next stable release.

Read more comments on GitHub >

github_iconTop Results From Across the Web

entry_points does not create custom scripts with pip, only with ...
I had a similar experience of pip install . not working from the project's directory. It turned out that pip wasn't executing all...
Read more >
setup.py entry_points: different behavior between local source ...
Pip doesn't build things when installing them. setup.cfg tells setuptools how to build things. The difference in install scripts comes from ...
Read more >
Python Apps the Right Way: entry points and scripts
If you're interested, read on to learn more! Requirements and Desired Results. You will need: a Python project. a setup.py file using setuptools....
Read more >
Python Entry Points Explained - Amir Rachum's Blog
This is super useful if you want to let other people write Python packages that interact or add abilities to your existing Python...
Read more >
Main() and command-line arguments | Microsoft Learn
There can only be one entry point in a C# program. If you have more than one class that has a Main method,...
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