python-3.xpippyobjc

Getting error in installing PyObjC in virtual environment


I have created a virtual environment and doing a speech assistant. While trying to install PyObjC, I am getting the following error. I am using windows.. Any alternatives for that?

 (venv) PS C:\Anirudh\Python\ani_speech_assistant> pip install PyObjC
    Collecting PyObjC
      Using cached pyobjc-6.2.2-py3-none-any.whl (2.9 kB)
    Collecting pyobjc-framework-InterfaceBuilderKit==6.2.2; platform_release >= "9.0" and platform_release < "11.0"
      Downloading pyobjc_framework_InterfaceBuilderKit-6.2.2-py2.py3-none-any.whl (5.8 kB)
    Collecting pyobjc-framework-XgridFoundation==6.2.2; platform_release < "12.0"
      Downloading pyobjc_framework_XgridFoundation-6.2.2-py2.py3-none-any.whl (5.1 kB)
    Collecting pyobjc-framework-LatentSemanticMapping==6.2.2
      Downloading pyobjc_framework_LatentSemanticMapping-6.2.2-py2.py3-none-any.whl (5.1 kB)
    Collecting pyobjc-framework-CoreAudioKit==6.2.2
      Downloading pyobjc-framework-CoreAudioKit-6.2.2.tar.gz (18 kB)
        ERROR: Command errored out with exit status 1:
         command: 'c:\anirudh\python\ani_speech_assistant\venv\scripts\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\aayan\\AppData\\Local\\Temp\\pip-install-mdbc0h_a\\pyobjc-framework-coreaudiokit\\setup.py'"'"'; __file__='"'"'C:\\Users\\aayan\\AppData\\Local\\Temp\\pip-install-mdbc0h_a\\pyobjc-framework-coreaudiokit\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base 'C:\Users\aayan\AppData\Local\Temp\pip-pip-egg-info-rwdv5gvi'
             cwd: C:\Users\aayan\AppData\Local\Temp\pip-install-mdbc0h_a\pyobjc-framework-coreaudiokit\
        Complete output (7 lines):
        Traceback (most recent call last):
          File "<string>", line 1, in <module>
          File "C:\Users\aayan\AppData\Local\Temp\pip-install-mdbc0h_a\pyobjc-framework-coreaudiokit\setup.py", line 28, in <module>
            Extension(
          File "C:\Users\aayan\AppData\Local\Temp\pip-install-mdbc0h_a\pyobjc-framework-coreaudiokit\pyobjc_setup.py", line 420, in Extension
            if "clang" in get_config_var("CC"):
        TypeError: argument of type 'NoneType' is not iterable
        ----------------------------------------
    ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

Solution

  • You can only install PyObjC in a macos. I think you are trying it on windows.