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.

error while compiling for windows

See original GitHub issue

when I try to compile electrum from the master branch (commit 69c5375cc51fe320b47b4797e97aa2b02614fae7), the process fails. At the same time, version 4.2.0 compiles without problems (commit eb8ab74698b5cb8bc35da9e5baa604715c543de1) compiling on ubuntu 20.04

💬 INFO:  Installing PyInstaller.
Processing c:\electrum\contrib\build-wine\.cache\win32\pyinstaller
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... error
  error: subprocess-exited-with-error

  × Preparing metadata (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [42 lines of output]
      Traceback (most recent call last):
        File "C:\python3\lib\site-packages\pip\_vendor\pep517\in_process\_in_pro
cess.py", line 363, in <module>
          main()
        File "C:\python3\lib\site-packages\pip\_vendor\pep517\in_process\_in_pro
cess.py", line 345, in main
          json_out['return_val'] = hook(**hook_input['kwargs'])
        File "C:\python3\lib\site-packages\pip\_vendor\pep517\in_process\_in_pro
cess.py", line 164, in prepare_metadata_for_build_wheel
          return hook(metadata_directory, config_settings)
        File "C:\users\user\Temp\pip-build-env-ki1x1hsr\overlay\Lib\site-package
s\setuptools\build_meta.py", line 188, in prepare_metadata_for_build_wheel
          self.run_setup()
        File "C:\users\user\Temp\pip-build-env-ki1x1hsr\overlay\Lib\site-package
s\setuptools\build_meta.py", line 281, in run_setup
          super(_BuildMetaLegacyBackend,
        File "C:\users\user\Temp\pip-build-env-ki1x1hsr\overlay\Lib\site-package
s\setuptools\build_meta.py", line 174, in run_setup
          exec(compile(code, __file__, 'exec'), locals())
        File "setup.py", line 249, in <module>
          setup(
        File "C:\users\user\Temp\pip-build-env-ki1x1hsr\overlay\Lib\site-package
s\setuptools\__init__.py", line 77, in setup
          return distutils.core.setup(**attrs)
        File "C:\users\user\Temp\pip-build-env-ki1x1hsr\overlay\Lib\site-package
s\setuptools\_distutils\core.py", line 122, in setup
          dist.parse_config_files()
        File "C:\users\user\Temp\pip-build-env-ki1x1hsr\overlay\Lib\site-package
s\setuptools\dist.py", line 832, in parse_config_files
          setupcfg.parse_configuration(
        File "C:\users\user\Temp\pip-build-env-ki1x1hsr\overlay\Lib\site-package
s\setuptools\config\setupcfg.py", line 167, in parse_configuration
          meta.parse()
        File "C:\users\user\Temp\pip-build-env-ki1x1hsr\overlay\Lib\site-package
s\setuptools\config\setupcfg.py", line 446, in parse
          section_parser_method(section_options)
        File "C:\users\user\Temp\pip-build-env-ki1x1hsr\overlay\Lib\site-package
s\setuptools\config\setupcfg.py", line 417, in parse_section
          self[name] = value
        File "C:\users\user\Temp\pip-build-env-ki1x1hsr\overlay\Lib\site-package
s\setuptools\config\setupcfg.py", line 238, in __setitem__
          value = parser(value)
        File "C:\users\user\Temp\pip-build-env-ki1x1hsr\overlay\Lib\site-package
s\setuptools\config\setupcfg.py", line 552, in _parse_version
          return expand.version(self._parse_attr(value, self.package_dir, self.r
oot_dir))
        File "C:\users\user\Temp\pip-build-env-ki1x1hsr\overlay\Lib\site-package
s\setuptools\config\setupcfg.py", line 372, in _parse_attr
          return expand.read_attr(attr_desc, package_dir, root_dir)
        File "C:\users\user\Temp\pip-build-env-ki1x1hsr\overlay\Lib\site-package
s\setuptools\config\expand.py", line 186, in read_attr
          module = _load_spec(spec, module_name)
        File "C:\users\user\Temp\pip-build-env-ki1x1hsr\overlay\Lib\site-package
s\setuptools\config\expand.py", line 206, in _load_spec
          spec.loader.exec_module(module)  # type: ignore
        File "<frozen importlib._bootstrap_external>", line 850, in exec_module
        File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_rem
oved
        File "C:\electrum\contrib\build-wine\.cache\win32\pyinstaller\PyInstalle
r.py", line 15, in <module>
          from PyInstaller.__main__ import run
      ModuleNotFoundError: No module named 'PyInstaller.__main__'; 'PyInstaller'
 is not a package
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem wit
h pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
WARNING: You are using pip version 22.0.3; however, version 22.0.4 is available.
You should consider upgrading via the 'C:\python3\python.exe -m pip install --up
grade pip' command.
🗯 ERROR: prepare-wine failed

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
SomberNightcommented, Mar 25, 2022

setuptools 61.0.0 got released a few hours ago (just before you opened the issue)

Looks like it’s the same issue as with https://github.com/spesmilo/electrum/commit/8559d1eb723c8c462c3d2a7365967ada46ef21c5 (“pip install” needs “–no-build-isolation”)

0reactions
SomberNightcommented, Mar 25, 2022

The same issue directly affects the macOS build as well.

Read more comments on GitHub >

github_iconTop Results From Across the Web

getting error while compiling program in command prompt
Hello there, I am unable to compile my program in command prompt. Whenever I try to compile it is always pointing to another...
Read more >
Error while compiling C++ code on Linux for Windows
#import and mscorlib are C++.NET (a C++-derived language by Microsoft®), not C++. MinGW doesn't and can't support that (C++.
Read more >
Error while compiling with MinGW on Windows.
1. Open Command Prompt for Windows. · 2. cd c:\wxWidgets\build\msw · 3. Type "mingw32-bin.exe -f makefile.gcc BUILD=debug" (without quotes). · 4.
Read more >
Errors while compiling on windows. · Issue #26 - GitHub
So I am trying to install this on windows, and I'm getting an odd error in SH.hpp that seems to be killing the...
Read more >
Error while compiling on WSL with Max Parallel Compilation ...
A fix for this issue has been released! Install the most recent release from https://visualstudio.microsoft.com/downloads/. Thank you for providing valuable ...
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