Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to compile modules listed under unworthy_namespaces #477

Open
tommyli3318 opened this issue Aug 1, 2019 · 1 comment

Comments

@tommyli3318
Copy link
Member

commented Aug 1, 2019

Error, implicit module 'pycparser.yacctab' expected by 'pycparser.c_parser' not found. is raised when python setup.py bdist_nutika is called for the package pycparser.
This is due to pycparser being listed under unworthy_namespaces in nuitka.plugins.standard.ImplicitImports.py

Platform: Windows
Python 3.7.0 (x32)
Nuitka 0.6.5rc3

Steps to reproduce:

  1. Create and activate a new virtualenv
  2. git clone https://github.com/eliben/pycparser.git
  3. cd pycparser
  4. python setup.py bdist_nuitka

Full traceback:

Error, implicit module 'pycparser.yacctab' expected by 'pycparser.c_parser' not found.
Traceback (most recent call last):
  File "setup.py", line 65, in <module>
    cmdclass={'install': install, 'sdist': sdist},
  File "C:\Users\Tommy\new\lib\site-packages\setuptools\__init__.py", line 145, in setup
    return distutils.core.setup(**attrs)
  File "c:\users\tommy\appdata\local\programs\python\python37-32\Lib\distutils\core.py", line 148, in setup
    dist.run_commands()
  File "c:\users\tommy\appdata\local\programs\python\python37-32\Lib\distutils\dist.py", line 966, in run_commands
    self.run_command(cmd)
  File "c:\users\tommy\appdata\local\programs\python\python37-32\Lib\distutils\dist.py", line 985, in run_command
    cmd_obj.run()
  File "C:\Users\Tommy\new\lib\site-packages\wheel\bdist_wheel.py", line 192, in run
    self.run_command('build')
  File "c:\users\tommy\appdata\local\programs\python\python37-32\Lib\distutils\cmd.py", line 313, in run_command
    self.distribution.run_command(command)
  File "c:\users\tommy\appdata\local\programs\python\python37-32\Lib\distutils\dist.py", line 985, in run_command
    cmd_obj.run()
  File "C:\Users\Tommy\new\lib\site-packages\nuitka\distutils\bdist_nuitka.py", line 60, in run
    self._buildPackage(os.path.abspath(self.build_lib))
  File "C:\Users\Tommy\new\lib\site-packages\nuitka\distutils\bdist_nuitka.py", line 141, in _buildPackage
    subprocess.check_call(command, cwd=build_lib)
  File "c:\users\tommy\appdata\local\programs\python\python37-32\Lib\subprocess.py", line 328, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['C:\\Users\\Tommy\\new\\Scripts\\python.exe', '-m', 'nuitka', '--module', '--plugin-enable=pylint-warnings', '--output-dir=C:\\Users\\Tommy\\new\\pycparser\\build\\lib', '--include-package=pycparser', '--nofollow-import-to=*.tests', '--show-modules', '--remove-output', 'C:\\Users\\Tommy\\new\\pycparser\\build\\lib\\pycparser']' returned non-zero exit status 1.
@kayhayen

This comment has been minimized.

Copy link
Member

commented Aug 1, 2019

I thought this had become not reprocidble. That should not really happen, and would indicate that maybe an extra step is missing.

For the error in the title of the issue, I have made changes on the factory branch, which will prevent including the top level module as bytecode, but warn about it. Everything else will not be compiled though, which is something to deal with in the future, when we add command line control of these things.

Yours,
Kay

@kayhayen kayhayen self-assigned this Aug 1, 2019

@kayhayen kayhayen added this to To do in Planning via automation Aug 4, 2019

@kayhayen kayhayen moved this from To do to Review in progress in Planning Aug 4, 2019

@kayhayen kayhayen moved this from Review in progress to Done in Planning Aug 4, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
2 participants
You can’t perform that action at this time.