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

PARL在MacOS系统上用pip安装的时候报错 #1122

Open
wanght73 opened this issue Aug 7, 2023 · 2 comments
Open

PARL在MacOS系统上用pip安装的时候报错 #1122

wanght73 opened this issue Aug 7, 2023 · 2 comments

Comments

@wanght73
Copy link

wanght73 commented Aug 7, 2023

安装到grpcio和pyzmq的时候等待几分钟后就开始报错,在MacOS上安装不了PARL。
Python3.11,3.10,都试了。安装最新版本的grpcio和pyzmq都可以,配套parl的版本
pyzmq==22.3.0
grpcio==1.37.0
都不行

错误信息如下:

      self._compile(obj, src, ext, cc_args, extra_postargs, pp_opts)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-install-mqf6odzv/grpcio_0c106e9e4ae44bebaf09b2ae33b973bf/src/python/grpcio/commands.py", line 265, in new_compile
      return old_compile(obj, src, ext, cc_args, extra_postargs,
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-cdlmb21a/overlay/lib/python3.11/site-packages/setuptools/_distutils/unixccompiler.py", line 187, in _compile
      raise CompileError(msg)
  distutils.errors.CompileError: command '/usr/bin/clang' failed with exit code 1
  
  [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for grpcio
Failed to build grpcio
ERROR: Could not build wheels for grpcio, which is required to install pyproject.toml-based projects

@wanght73
Copy link
Author

wanght73 commented Aug 9, 2023

完整报错内容如下:

` Traceback (most recent call last):
File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/unixccompiler.py", line 185, in _compile
self.spawn(compiler_so + cc_args + [src, '-o', obj] + extra_postargs)
File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-install-8kml27lq/grpcio_93452c678d5844d59075671ff9a272c3/src/python/grpcio/_spawn_patch.py", line 54, in _commandfile_spawn
_classic_spawn(self, command)
File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/ccompiler.py", line 1041, in spawn
spawn(cmd, dry_run=self.dry_run, **kwargs)
File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/spawn.py", line 70, in spawn
raise DistutilsExecError(
distutils.errors.DistutilsExecError: command '/usr/bin/clang' failed with exit code 1

  During handling of the above exception, another exception occurred:
  
  Traceback (most recent call last):
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-install-8kml27lq/grpcio_93452c678d5844d59075671ff9a272c3/src/python/grpcio/commands.py", line 282, in build_extensions
      build_ext.build_ext.build_extensions(self)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/command/build_ext.py", line 467, in build_extensions
      self._build_extensions_serial()
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/command/build_ext.py", line 493, in _build_extensions_serial
      self.build_extension(ext)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/command/build_ext.py", line 246, in build_extension
      _build_ext.build_extension(self, ext)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/command/build_ext.py", line 548, in build_extension
      objects = self.compiler.compile(
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-install-8kml27lq/grpcio_93452c678d5844d59075671ff9a272c3/src/python/grpcio/_parallel_compile_patch.py", line 58, in _parallel_compile
      multiprocessing.pool.ThreadPool(BUILD_EXT_COMPILER_JOBS).map(
    File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/multiprocessing/pool.py", line 364, in map
      return self._map_async(func, iterable, mapstar, chunksize).get()
    File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/multiprocessing/pool.py", line 771, in get
      raise self._value
    File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/multiprocessing/pool.py", line 125, in worker
      result = (True, func(*args, **kwds))
    File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/multiprocessing/pool.py", line 48, in mapstar
      return list(map(*args))
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-install-8kml27lq/grpcio_93452c678d5844d59075671ff9a272c3/src/python/grpcio/_parallel_compile_patch.py", line 54, in _compile_single_file
      self._compile(obj, src, ext, cc_args, extra_postargs, pp_opts)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-install-8kml27lq/grpcio_93452c678d5844d59075671ff9a272c3/src/python/grpcio/commands.py", line 265, in new_compile
      return old_compile(obj, src, ext, cc_args, extra_postargs,
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/unixccompiler.py", line 187, in _compile
      raise CompileError(msg)
  distutils.errors.CompileError: command '/usr/bin/clang' failed with exit code 1
  
  During handling of the above exception, another exception occurred:
  
  Traceback (most recent call last):
    File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
      main()
    File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
      json_out['return_val'] = hook(**hook_input['kwargs'])
    File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 251, in build_wheel
      return _build_backend().build_wheel(wheel_directory, config_settings,
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 416, in build_wheel
      return self._build_with_temp_dir(['bdist_wheel'], '.whl',
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 401, in _build_with_temp_dir
      self.run_setup()
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 487, in run_setup
      super(_BuildMetaLegacyBackend,
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 338, in run_setup
      exec(code, locals())
    File "<string>", line 508, in <module>
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/__init__.py", line 107, in setup
      return distutils.core.setup(**attrs)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/core.py", line 185, in setup
      return run_commands(dist)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/core.py", line 201, in run_commands
      dist.run_commands()
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 969, in run_commands
      self.run_command(cmd)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/dist.py", line 1234, in run_command
      super().run_command(command)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
      cmd_obj.run()
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/wheel/bdist_wheel.py", line 349, in run
      self.run_command("build")
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/cmd.py", line 318, in run_command
      self.distribution.run_command(command)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/dist.py", line 1234, in run_command
      super().run_command(command)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
      cmd_obj.run()
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/command/build.py", line 131, in run
      self.run_command(cmd_name)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/cmd.py", line 318, in run_command
      self.distribution.run_command(command)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/dist.py", line 1234, in run_command
      super().run_command(command)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
      cmd_obj.run()
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/command/build_ext.py", line 84, in run
      _build_ext.run(self)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/command/build_ext.py", line 345, in run
      self.build_extensions()
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-install-8kml27lq/grpcio_93452c678d5844d59075671ff9a272c3/src/python/grpcio/commands.py", line 286, in build_extensions
      raise CommandError(
  commands.CommandError: Failed `build_ext` step:
  Traceback (most recent call last):
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/unixccompiler.py", line 185, in _compile
      self.spawn(compiler_so + cc_args + [src, '-o', obj] + extra_postargs)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-install-8kml27lq/grpcio_93452c678d5844d59075671ff9a272c3/src/python/grpcio/_spawn_patch.py", line 54, in _commandfile_spawn
      _classic_spawn(self, command)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/ccompiler.py", line 1041, in spawn
      spawn(cmd, dry_run=self.dry_run, **kwargs)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/spawn.py", line 70, in spawn
      raise DistutilsExecError(
  distutils.errors.DistutilsExecError: command '/usr/bin/clang' failed with exit code 1
  
  During handling of the above exception, another exception occurred:
  
  Traceback (most recent call last):
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-install-8kml27lq/grpcio_93452c678d5844d59075671ff9a272c3/src/python/grpcio/commands.py", line 282, in build_extensions
      build_ext.build_ext.build_extensions(self)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/command/build_ext.py", line 467, in build_extensions
      self._build_extensions_serial()
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/command/build_ext.py", line 493, in _build_extensions_serial
      self.build_extension(ext)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/command/build_ext.py", line 246, in build_extension
      _build_ext.build_extension(self, ext)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/command/build_ext.py", line 548, in build_extension
      objects = self.compiler.compile(
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-install-8kml27lq/grpcio_93452c678d5844d59075671ff9a272c3/src/python/grpcio/_parallel_compile_patch.py", line 58, in _parallel_compile
      multiprocessing.pool.ThreadPool(BUILD_EXT_COMPILER_JOBS).map(
    File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/multiprocessing/pool.py", line 364, in map
      return self._map_async(func, iterable, mapstar, chunksize).get()
    File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/multiprocessing/pool.py", line 771, in get
      raise self._value
    File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/multiprocessing/pool.py", line 125, in worker
      result = (True, func(*args, **kwds))
    File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/multiprocessing/pool.py", line 48, in mapstar
      return list(map(*args))
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-install-8kml27lq/grpcio_93452c678d5844d59075671ff9a272c3/src/python/grpcio/_parallel_compile_patch.py", line 54, in _compile_single_file
      self._compile(obj, src, ext, cc_args, extra_postargs, pp_opts)
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-install-8kml27lq/grpcio_93452c678d5844d59075671ff9a272c3/src/python/grpcio/commands.py", line 265, in new_compile
      return old_compile(obj, src, ext, cc_args, extra_postargs,
    File "/private/var/folders/0f/4fvchbvj5b34x5xx5h02k_100000gn/T/pip-build-env-v95lvzno/overlay/lib/python3.10/site-packages/setuptools/_distutils/unixccompiler.py", line 187, in _compile
      raise CompileError(msg)
  distutils.errors.CompileError: command '/usr/bin/clang' failed with exit code 1
  
  [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for grpcio
Failed to build grpcio
ERROR: Could not build wheels for grpcio, which is required to install pyproject.toml-based projects`

@niudakok
Copy link

niudakok commented Feb 8, 2024

我在win11 python3.12 中安装也是这两个包装不上 一样的报错

ERROR: Failed building wheel for grpcio
Failed to build grpcio
ERROR: Could not build wheels for grpcio, which is required to install pyproject.toml-based projects`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants