Visual Studion 2019 not supported by Scons
See original GitHub issueBefore submitting an Issue, please review the Issue Guidelines.
-
Please check whether the bug was already reported or fixed.
-
Please check out if the develop version of Nuitka works better for you.
Download source, packages from here where you will also find instructions how to do it via PyPI.
If you want to post a problem/bug, to help us understand and resolve your issue please check that you have provided at least the information below, and discard up to here:
-
Nuitka version, full Python version and Platform (Windows, OSX, Linux …)
python -m nuitka --version 0.6.4 Python: 3.7.3 (v3.7.3:ef4ec6ed12, Mar 25 2019, 22:22:05) [MSC v.1916 64 bit (AMD64)] OS: Windows Arch: x86_64 wsPython: 4.0
-
How did you install Nuitka and Python (pip, anaconda, deb, rpm, from source, what is a virtualenv …), this is very important usually.
Nuitka and Python both from Windows installers (msi)
-
Many times when you get an error from Nuitka, your setup may be so special that even a “hello world” program will not work, please try that and report it instead.
-
If possible please supply a Short, Self Contained, Correct, Example that demonstrates the issue i.e a small piece of code which reproduces the issue and can be run with out any other (or as few as possible) external dependencies.
import wx
class MyFrame(wx.Frame):
def __init__(self):
super().__init__(self,parent=None, title='Hello World')
panel = wx.Panel(self)
self.Show()
if __name__ == '__main__':
app = wx.App()
frame = MyFrame()
app.MainLoop()
- If this is a regression (used to work in an earlier version of Nuitka), please note what you know about that.
I’m trying to compile the example above into exe
using the command py -m nuitka --follow-imports --standalone example.py
but I’m getting the following error
IndexError: list index out of range:
File "C:\Users\enahm\AppData\Local\Programs\Python\Python37\lib\site-packages\nuitka\build\SingleExe.scons", line 500:
env = createEnvironment(compiler_tools=compiler_tools)
File "C:\Users\enahm\AppData\Local\Programs\Python\Python37\lib\site-packages\nuitka\build\SingleExe.scons", line 485:
**args
File "C:\Users\enahm\AppData\Local\Programs\Python\Python37\lib\site-packages\nuitka\build\inline_copy\lib\scons-3.0.4\SCons\Environment.py", line 982:
apply_tools(self, tools, toolpath)
File "C:\Users\enahm\AppData\Local\Programs\Python\Python37\lib\site-packages\nuitka\build\inline_copy\lib\scons-3.0.4\SCons\Environment.py", line 107:
env.Tool(tool)
File "C:\Users\enahm\AppData\Local\Programs\Python\Python37\lib\site-packages\nuitka\build\inline_copy\lib\scons-3.0.4\SCons\Environment.py", line 1789:
tool(self)
File "C:\Users\enahm\AppData\Local\Programs\Python\Python37\lib\site-packages\nuitka\build\inline_copy\lib\scons-3.0.4\SCons\Tool\__init__.py", line 299:
self.generate(env, *args, **kw)
File "C:\Users\enahm\AppData\Local\Programs\Python\Python37\lib\site-packages\nuitka\build\inline_copy\lib\scons-3.0.4\SCons\Tool\default.py", line 40:
for t in SCons.Tool.tool_list(env['PLATFORM'], env):
File "C:\Users\enahm\AppData\Local\Programs\Python\Python37\lib\site-packages\nuitka\build\inline_copy\lib\scons-3.0.4\SCons\Tool\__init__.py", line 1271:
c_compiler = FindTool(c_compilers, env) or c_compilers[0]
File "C:\Users\enahm\AppData\Local\Programs\Python\Python37\lib\site-packages\nuitka\build\inline_copy\lib\scons-3.0.4\SCons\Tool\__init__.py", line 1172:
if t.exists(env):
File "C:\Users\enahm\AppData\Local\Programs\Python\Python37\lib\site-packages\nuitka\build\inline_copy\lib\scons-3.0.4\SCons\Tool\msvc.py", line 292:
return msvc_exists(env)
File "C:\Users\enahm\AppData\Local\Programs\Python\Python37\lib\site-packages\nuitka\build\inline_copy\lib\scons-3.0.4\SCons\Tool\MSCommon\vc.py", line 759:
vcs = cached_get_installed_vcs(env)
File "C:\Users\enahm\AppData\Local\Programs\Python\Python37\lib\site-packages\nuitka\build\inline_copy\lib\scons-3.0.4\SCons\Tool\MSCommon\vc.py", line 524:
ret = get_installed_vcs(env)
File "C:\Users\enahm\AppData\Local\Programs\Python\Python37\lib\site-packages\nuitka\build\inline_copy\lib\scons-3.0.4\SCons\Tool\MSCommon\vc.py", line 535:
VC_DIR = find_vc_pdir(ver)
File "C:\Users\enahm\AppData\Local\Programs\Python\Python37\lib\site-packages\nuitka\build\inline_copy\lib\scons-3.0.4\SCons\Tool\MSCommon\vc.py", line 344:
comps = find_vc_pdir_vswhere(msvc_version)
File "C:\Users\enahm\AppData\Local\Programs\Python\Python37\lib\site-packages\nuitka\build\inline_copy\lib\scons-3.0.4\SCons\Tool\MSCommon\vc.py", line 306:
vc_pdir = os.path.join(vsdir[0], 'VC')
Issue Analytics
- State:
- Created 4 years ago
- Comments:11 (7 by maintainers)
Top GitHub Comments
@AhmedMKamal if you wait a moment, I will update to Scons 3.0.5, and maybe it does MSVC 16.
Also, I think VS 2017 is 14.1 or something, they screwed with the numbering.
You can also go with MinGW64, which from my cursory testing gives smaller and faster binaries. See #148 reports.
Yours, Kay
Released as 0.6.5 with newer scons that handles this, also VS 2019 is final and works better.