2

我尝试安装 picamera ( pip install picamera) 并收到以下错误:

ERROR: Command errored out with exit status 1:

有人可以帮忙吗?Python 3.9.1 点 20.3.3

Full error message:
ERROR: Command errored out with exit status 1:
   command: /usr/local/opt/python@3.9/bin/python3.9 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/setup.py'"'"'; __file__='"'"'/private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-wheel-x36s0i1b
       cwd: /private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/
  Complete output (61 lines):
  running bdist_wheel
  running build
  running build_py
  creating build
  creating build/lib
  creating build/lib/picamera
  copying picamera/streams.py -> build/lib/picamera
  copying picamera/color.py -> build/lib/picamera
  copying picamera/__init__.py -> build/lib/picamera
  copying picamera/encoders.py -> build/lib/picamera
  copying picamera/renderers.py -> build/lib/picamera
  copying picamera/display.py -> build/lib/picamera
  copying picamera/camera.py -> build/lib/picamera
  copying picamera/frames.py -> build/lib/picamera
  copying picamera/exc.py -> build/lib/picamera
  copying picamera/bcm_host.py -> build/lib/picamera
  copying picamera/mmalobj.py -> build/lib/picamera
  copying picamera/array.py -> build/lib/picamera
  copying picamera/mmal.py -> build/lib/picamera
  running egg_info
  writing picamera.egg-info/PKG-INFO
  writing dependency_links to picamera.egg-info/dependency_links.txt
  writing requirements to picamera.egg-info/requires.txt
  writing top-level names to picamera.egg-info/top_level.txt
  reading manifest file 'picamera.egg-info/SOURCES.txt'
  reading manifest template 'MANIFEST.in'
  no previously-included directories found matching 'debian'
  no previously-included directories found matching 'docs'
  writing manifest file 'picamera.egg-info/SOURCES.txt'
  installing to build/bdist.macosx-10.15-x86_64/wheel
  running install
  Traceback (most recent call last):
    File "/private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/setup.py", line 101, in run
      with io.open('/proc/cpuinfo', 'r') as cpuinfo:
  FileNotFoundError: [Errno 2] No such file or directory: '/proc/cpuinfo'
  
  During handling of the above exception, another exception occurred:
  
  Traceback (most recent call last):
    File "<string>", line 1, in <module>
    File "/private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/setup.py", line 145, in <module>
      main()
    File "/private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/setup.py", line 119, in main
      setup(
    File "/usr/local/lib/python3.9/site-packages/setuptools/__init__.py", line 153, in setup
      return distutils.core.setup(**attrs)
    File "/usr/local/Cellar/python@3.9/3.9.1_3/Frameworks/Python.framework/Versions/3.9/lib/python3.9/distutils/core.py", line 148, in setup
      dist.run_commands()
    File "/usr/local/Cellar/python@3.9/3.9.1_3/Frameworks/Python.framework/Versions/3.9/lib/python3.9/distutils/dist.py", line 966, in run_commands
      self.run_command(cmd)
    File "/usr/local/Cellar/python@3.9/3.9.1_3/Frameworks/Python.framework/Versions/3.9/lib/python3.9/distutils/dist.py", line 985, in run_command
      cmd_obj.run()
    File "/usr/local/lib/python3.9/site-packages/wheel/bdist_wheel.py", line 335, in run
      self.run_command('install')
    File "/usr/local/Cellar/python@3.9/3.9.1_3/Frameworks/Python.framework/Versions/3.9/lib/python3.9/distutils/cmd.py", line 313, in run_command
      self.distribution.run_command(command)
    File "/usr/local/Cellar/python@3.9/3.9.1_3/Frameworks/Python.framework/Versions/3.9/lib/python3.9/distutils/dist.py", line 985, in run_command
      cmd_obj.run()
    File "/private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/setup.py", line 113, in run
      raise ValueError('Unable to open /proc/cpuinfo')
  ValueError: Unable to open /proc/cpuinfo
  ----------------------------------------
  ERROR: Failed building wheel for picamera
  Running setup.py clean for picamera
Failed to build picamera
Installing collected packages: picamera
    Running setup.py install for picamera ... error
    ERROR: Command errored out with exit status 1:
     command: /usr/local/opt/python@3.9/bin/python3.9 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/setup.py'"'"'; __file__='"'"'/private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-record-qme1_imo/install-record.txt --single-version-externally-managed --compile --install-headers /usr/local/include/python3.9/picamera
         cwd: /private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/
    Complete output (25 lines):
    running install
    Traceback (most recent call last):
      File "/private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/setup.py", line 101, in run
        with io.open('/proc/cpuinfo', 'r') as cpuinfo:
    FileNotFoundError: [Errno 2] No such file or directory: '/proc/cpuinfo'
    
    During handling of the above exception, another exception occurred:
    
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/setup.py", line 145, in <module>
        main()
      File "/private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/setup.py", line 119, in main
        setup(
      File "/usr/local/lib/python3.9/site-packages/setuptools/__init__.py", line 153, in setup
        return distutils.core.setup(**attrs)
      File "/usr/local/Cellar/python@3.9/3.9.1_3/Frameworks/Python.framework/Versions/3.9/lib/python3.9/distutils/core.py", line 148, in setup
        dist.run_commands()
      File "/usr/local/Cellar/python@3.9/3.9.1_3/Frameworks/Python.framework/Versions/3.9/lib/python3.9/distutils/dist.py", line 966, in run_commands
        self.run_command(cmd)
      File "/usr/local/Cellar/python@3.9/3.9.1_3/Frameworks/Python.framework/Versions/3.9/lib/python3.9/distutils/dist.py", line 985, in run_command
        cmd_obj.run()
      File "/private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/setup.py", line 113, in run
        raise ValueError('Unable to open /proc/cpuinfo')
    ValueError: Unable to open /proc/cpuinfo
    ----------------------------------------
ERROR: Command errored out with exit status 1: /usr/local/opt/python@3.9/bin/python3.9 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/setup.py'"'"'; __file__='"'"'/private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-install-rhshjkgn/picamera_1bc7cc4f85134726b19ddbe1c70f3c0a/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /private/var/folders/mk/d5qfrxc13nb6rq4d1v_ntzp40000gn/T/pip-record-qme1_imo/install-record.txt --single-version-externally-managed --compile --install-headers /usr/local/include/python3.9/picamera Check the logs for full command output.
4

0 回答 0