Install fails via pipx due to aiohttp wheel build failure
Open
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 12.5k
- Forks
- 998
- Avg merge
- 3d 13h
- Merged PRs (30d)
- 10
Description
System & Python info:
➜ ~ python3 --version
Python 3.11.6
➜ ~ which python3
/opt/homebrew/bin/python3
➜ ~ pipx --version
1.2.1
➜ ~ uname -a
Darwin akgerbers-MacBook-Pro.local 23.1.0 Darwin Kernel Version 23.1.0: Mon Oct 9 21:27:24 PDT 2023; root:xnu-10002.41.9~6/RELEASE_ARM64_T6000 arm64
An Install attempted via pipx install llm immediately after brew install pipx (and also in a new terminal instance) fails as such:
➜ ~ pipx install llm
Fatal error from pip prevented installation. Full pip output in file:
/Users/akgerber/.local/pipx/logs/cmd_2023-11-09_20.11.32_pip_errors.log
pip failed to build package:
aiohttp
Some possibly relevant errors from pip install:
error: subprocess-exited-with-error
aiohttp/_websocket.c:3042:55: error: no member named 'ob_digit' in 'struct _longobject'
aiohttp/_websocket.c:3097:55: error: no member named 'ob_digit' in 'struct _longobject'
aiohttp/_websocket.c:3238:55: error: no member named 'ob_digit' in 'struct _longobject'
aiohttp/_websocket.c:3293:55: error: no member named 'ob_digit' in 'struct _longobject'
aiohttp/_websocket.c:3744:47: error: no member named 'ob_digit' in 'struct _longobject'
error: command '/usr/bin/clang' failed with exit code 1
Error installing llm.
The full log output is:
PIP STDOUT
----------
Collecting llm
Using cached llm-0.12-py3-none-any.whl.metadata (6.0 kB)
Collecting click (from llm)
Using cached click-8.1.7-py3-none-any.whl.metadata (3.0 kB)
Collecting openai<1.0 (from llm)
Using cached openai-0.28.1-py3-none-any.whl.metadata (11 kB)
Collecting click-default-group>=1.2.3 (from llm)
Using cached click_default_group-1.2.4-py2.py3-none-any.whl.metadata (2.8 kB)
Collecting sqlite-utils>=3.35.0 (from llm)
Using cached sqlite_utils-3.35.2-py3-none-any.whl.metadata (7.6 kB)
Collecting sqlite-migrate>=0.1a2 (from llm)
Using cached sqlite_migrate-0.1b0-py3-none-any.whl.metadata (5.4 kB)
Collecting pydantic>=1.10.2 (from llm)
Using cached pydantic-2.4.2-py3-none-any.whl.metadata (158 kB)
Collecting PyYAML (from llm)
Using cached PyYAML-6.0.1-cp312-cp312-macosx_11_0_arm64.whl.metadata (2.1 kB)
Collecting pluggy (from llm)
Using cached pluggy-1.3.0-py3-none-any.whl.metadata (4.3 kB)
Collecting python-ulid (from llm)
Using cached python_ulid-2.2.0-py3-none-any.whl.metadata (3.9 kB)
Requirement already satisfied: setuptools in ./.local/pipx/shared/lib/python3.12/site-packages (from llm) (68.2.2)
Requirement already satisfied: pip in ./.local/pipx/shared/lib/python3.12/site-packages (from llm) (23.3.1)
Collecting requests>=2.20 (from openai<1.0->llm)
Using cached requests-2.31.0-py3-none-any.whl.metadata (4.6 kB)
Collecting tqdm (from openai<1.0->llm)
Using cached tqdm-4.66.1-py3-none-any.whl.metadata (57 kB)
Collecting aiohttp (from openai<1.0->llm)
Using cached aiohttp-3.8.6.tar.gz (7.4 MB)
Installing build dependencies: started
Installing build dependencies: finished with status 'done'
Getting requirements to build wheel: started
Getting requirements to build wheel: finished with status 'done'
Installing backend dependencies: started
Installing backend dependencies: finished with status 'done'
Preparing metadata (pyproject.toml): started
Preparing metadata (pyproject.toml): finished with status 'done'
Collecting annotated-types>=0.4.0 (from pydantic>=1.10.2->llm)
Using cached annotated_types-0.6.0-py3-none-any.whl.metadata (12 kB)
Collecting pydantic-core==2.10.1 (from pydantic>=1.10.2->llm)
Using cached pydantic_core-2.10.1-cp312-cp312-macosx_11_0_arm64.whl.metadata (6.5 kB)
Collecting typing-extensions>=4.6.1 (from pydantic>=1.10.2->llm)
Using cached typing_extensions-4.8.0-py3-none-any.whl.metadata (3.0 kB)
Collecting sqlite-fts4 (from sqlite-utils>=3.35.0->llm)
Using cached sqlite_fts4-1.0.3-py3-none-any.whl (10.0 kB)
Collecting tabulate (from sqlite-utils>=3.35.0->llm)
Using cached tabulate-0.9.0-py3-none-any.whl (35 kB)
Collecting python-dateutil (from sqlite-utils>=3.35.0->llm)
Using cached python_dateutil-2.8.2-py2.py3-none-any.whl (247 kB)
Collecting charset-normalizer<4,>=2 (from requests>=2.20->openai<1.0->llm)
Using cached charset_normalizer-3.3.2-cp312-cp312-macosx_11_0_arm64.whl.metadata (33 kB)
Collecting idna<4,>=2.5 (from requests>=2.20->openai<1.0->llm)
Using cached idna-3.4-py3-none-any.whl (61 kB)
Collecting urllib3<3,>=1.21.1 (from requests>=2.20->openai<1.0->llm)
Using cached urllib3-2.0.7-py3-none-any.whl.metadata (6.6 kB)
Collecting certifi>=2017.4.17 (from requests>=2.20->openai<1.0->llm)
Using cached certifi-2023.7.22-py3-none-any.whl.metadata (2.2 kB)
Collecting attrs>=17.3.0 (from aiohttp->openai<1.0->llm)
Using cached attrs-23.1.0-py3-none-any.whl (61 kB)
Collecting multidict<7.0,>=4.5 (from aiohttp->openai<1.0->llm)
Using cached multidict-6.0.4-cp312-cp312-macosx_14_0_arm64.whl
Collecting async-timeout<5.0,>=4.0.0a3 (from aiohttp->openai<1.0->llm)
Using cached async_timeout-4.0.3-py3-none-any.whl.metadata (4.2 kB)
Collecting yarl<2.0,>=1.0 (from aiohttp->openai<1.0->llm)
Using cached yarl-1.9.2-cp312-cp312-macosx_14_0_arm64.whl
Collecting frozenlist>=1.1.1 (from aiohttp->openai<1.0->llm)
Using cached frozenlist-1.4.0-cp312-cp312-macosx_14_0_arm64.whl
Collecting aiosignal>=1.1.2 (from aiohttp->openai<1.0->llm)
Using cached aiosignal-1.3.1-py3-none-any.whl (7.6 kB)
Collecting six>=1.5 (from python-dateutil->sqlite-utils>=3.35.0->llm)
Using cached six-1.16.0-py2.py3-none-any.whl (11 kB)
Using cached llm-0.12-py3-none-any.whl (36 kB)
Using cached click_default_group-1.2.4-py2.py3-none-any.whl (4.1 kB)
Using cached openai-0.28.1-py3-none-any.whl (76 kB)
Using cached pydantic-2.4.2-py3-none-any.whl (395 kB)
Using cached pydantic_core-2.10.1-cp312-cp312-macosx_11_0_arm64.whl (1.7 MB)
Using cached sqlite_migrate-0.1b0-py3-none-any.whl (10.0 kB)
Using cached sqlite_utils-3.35.2-py3-none-any.whl (67 kB)
Using cached click-8.1.7-py3-none-any.whl (97 kB)
Using cached pluggy-1.3.0-py3-none-any.whl (18 kB)
Using cached python_ulid-2.2.0-py3-none-any.whl (9.4 kB)
Using cached PyYAML-6.0.1-cp312-cp312-macosx_11_0_arm64.whl (165 kB)
Using cached annotated_types-0.6.0-py3-none-any.whl (12 kB)
Using cached requests-2.31.0-py3-none-any.whl (62 kB)
Using cached typing_extensions-4.8.0-py3-none-any.whl (31 kB)
Using cached tqdm-4.66.1-py3-none-any.whl (78 kB)
Using cached async_timeout-4.0.3-py3-none-any.whl (5.7 kB)
Using cached certifi-2023.7.22-py3-none-any.whl (158 kB)
Using cached charset_normalizer-3.3.2-cp312-cp312-macosx_11_0_arm64.whl (119 kB)
Using cached urllib3-2.0.7-py3-none-any.whl (124 kB)
Building wheels for collected packages: aiohttp
Building wheel for aiohttp (pyproject.toml): started
Building wheel for aiohttp (pyproject.toml): finished with status 'error'
Failed to build aiohttp
PIP STDERR
----------
error: subprocess-exited-with-error
× Building wheel for aiohttp (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [188 lines of output]
*********************
* Accelerated build *
*********************
running bdist_wheel
running build
running build_py
creating build
creating build/lib.macosx-14-arm64-cpython-312
creating build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/web_ws.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/worker.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/multipart.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/web_response.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/client_ws.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/test_utils.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/tracing.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/web_exceptions.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/web_middlewares.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/web.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/http_exceptions.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/web_app.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/streams.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/web_protocol.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/log.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/client.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/web_urldispatcher.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/web_request.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/http_websocket.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/client_proto.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/locks.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/__init__.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/web_runner.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/web_server.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/base_protocol.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/payload.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/client_reqrep.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/http.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/web_log.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/resolver.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/formdata.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/payload_streamer.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/web_routedef.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/connector.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/client_exceptions.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/typedefs.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/hdrs.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/web_fileresponse.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/http_writer.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/tcp_helpers.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/helpers.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/http_parser.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/cookiejar.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/pytest_plugin.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/abc.py -> build/lib.macosx-14-arm64-cpython-312/aiohttp
running egg_info
writing aiohttp.egg-info/PKG-INFO
writing dependency_links to aiohttp.egg-info/dependency_links.txt
writing requirements to aiohttp.egg-info/requires.txt
writing top-level names to aiohttp.egg-info/top_level.txt
reading manifest file 'aiohttp.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no files found matching 'aiohttp' anywhere in distribution
warning: no previously-included files matching '*.pyc' found anywhere in distribution
warning: no previously-included files matching '*.pyd' found anywhere in distribution
warning: no previously-included files matching '*.so' found anywhere in distribution
warning: no previously-included files matching '*.lib' found anywhere in distribution
warning: no previously-included files matching '*.dll' found anywhere in distribution
warning: no previously-included files matching '*.a' found anywhere in distribution
warning: no previously-included files matching '*.obj' found anywhere in distribution
warning: no previously-included files found matching 'aiohttp/*.html'
no previously-included directories found matching 'docs/_build'
adding license file 'LICENSE.txt'
writing manifest file 'aiohttp.egg-info/SOURCES.txt'
copying aiohttp/_cparser.pxd -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/_find_header.pxd -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/_headers.pxi -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/_helpers.pyi -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/_helpers.pyx -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/_http_parser.pyx -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/_http_writer.pyx -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/_websocket.pyx -> build/lib.macosx-14-arm64-cpython-312/aiohttp
copying aiohttp/py.typed -> build/lib.macosx-14-arm64-cpython-312/aiohttp
creating build/lib.macosx-14-arm64-cpython-312/aiohttp/.hash
copying aiohttp/.hash/_cparser.pxd.hash -> build/lib.macosx-14-arm64-cpython-312/aiohttp/.hash
copying aiohttp/.hash/_find_header.pxd.hash -> build/lib.macosx-14-arm64-cpython-312/aiohttp/.hash
copying aiohttp/.hash/_helpers.pyi.hash -> build/lib.macosx-14-arm64-cpython-312/aiohttp/.hash
copying aiohttp/.hash/_helpers.pyx.hash -> build/lib.macosx-14-arm64-cpython-312/aiohttp/.hash
copying aiohttp/.hash/_http_parser.pyx.hash -> build/lib.macosx-14-arm64-cpython-312/aiohttp/.hash
copying aiohttp/.hash/_http_writer.pyx.hash -> build/lib.macosx-14-arm64-cpython-312/aiohttp/.hash
copying aiohttp/.hash/_websocket.pyx.hash -> build/lib.macosx-14-arm64-cpython-312/aiohttp/.hash
copying aiohttp/.hash/hdrs.py.hash -> build/lib.macosx-14-arm64-cpython-312/aiohttp/.hash
running build_ext
building 'aiohttp._websocket' extension
creating build/temp.macosx-14-arm64-cpython-312
creating build/temp.macosx-14-arm64-cpython-312/aiohttp
clang -fno-strict-overflow -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -O3 -Wall -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX14.sdk -I/Users/akgerber/.local/pipx/venvs/llm/include -I/opt/homebrew/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12 -c aiohttp/_websocket.c -o build/temp.macosx-14-arm64-cpython-312/aiohttp/_websocket.o
aiohttp/_websocket.c:1475:17: warning: 'Py_OptimizeFlag' is deprecated [-Wdeprecated-declarations]
if (unlikely(!Py_OptimizeFlag)) {
^
/opt/homebrew/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12/cpython/pydebug.h:13:1: note: 'Py_OptimizeFlag' has been explicitly marked deprecated here
Py_DEPRECATED(3.12) PyAPI_DATA(int) Py_OptimizeFlag;
^
/opt/homebrew/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12/pyport.h:317:54: note: expanded from macro 'Py_DEPRECATED'
#define Py_DEPRECATED(VERSION_UNUSED) __attribute__((__deprecated__))
^
aiohttp/_websocket.c:2680:27: warning: 'ma_version_tag' is deprecated [-Wdeprecated-declarations]
return likely(dict) ? __PYX_GET_DICT_VERSION(dict) : 0;
^
aiohttp/_websocket.c:1118:65: note: expanded from macro '__PYX_GET_DICT_VERSION'
#define __PYX_GET_DICT_VERSION(dict) (((PyDictObject*)(dict))->ma_version_tag)
^
/opt/homebrew/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12/cpython/dictobject.h:22:5: note: 'ma_version_tag' has been explicitly marked deprecated here
Py_DEPRECATED(3.12) uint64_t ma_version_tag;
^
/opt/homebrew/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12/pyport.h:317:54: note: expanded from macro 'Py_DEPRECATED'
#define Py_DEPRECATED(VERSION_UNUSED) __attribute__((__deprecated__))
^
aiohttp/_websocket.c:2692:36: warning: 'ma_version_tag' is deprecated [-Wdeprecated-declarations]
return (dictptr && *dictptr) ? __PYX_GET_DICT_VERSION(*dictptr) : 0;
^
aiohttp/_websocket.c:1118:65: note: expanded from macro '__PYX_GET_DICT_VERSION'
#define __PYX_GET_DICT_VERSION(dict) (((PyDictObject*)(dict))->ma_version_tag)
^
/opt/homebrew/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12/cpython/dictobject.h:22:5: note: 'ma_version_tag' has been explicitly marked deprecated here
Py_DEPRECATED(3.12) uint64_t ma_version_tag;
^
/opt/homebrew/opt/python@3.12/Frameworks/Python.framework/Versions/3.12/include/python3.12/pyport.h:317:54: note: expanded from macro 'Py_DEPRECATED'
#define Py_DEPRECATED(VERSION_UNUSED) __attribute__((__deprecated__))
^
aiohttp/_websocket.c:3042:55: error: no member named 'ob_digit' in 'struct _longobject'
const digit* digits = ((PyLongObject*)x)->ob_digit;
~~~~~~~~~~~~~~~~~~ ^
aiohttp/_websocket.c:3097:55: error: no member named 'ob_digit' in 'struct _longobject'
const digit* digits = ((PyLongObject*)x)->ob_digit;
~~~~~~~~~~~~~~~~~~ ^
aiohttp/_websocket.c:3238:55: error: no member named 'ob_digit' in 'struct _longobject'
const digit* digits = ((PyLongObject*)x)->ob_digit;
~~~~~~~~~~~~~~~~~~ ^
aiohttp/_websocket.c:3293:55: error: no member named 'ob_digit' in 'struct _longobject'
const digit* digits = ((PyLongObject*)x)->ob_digit;
~~~~~~~~~~~~~~~~~~ ^
aiohttp/_websocket.c:3744:47: error: no member named 'ob_digit' in 'struct _longobject'
const digit* digits = ((PyLongObject*)b)->ob_digit;
~~~~~~~~~~~~~~~~~~ ^
6 warnings and 5 errors generated.
error: 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 aiohttp
ERROR: Could not build wheels for aiohttp, which is required to install pyproject.toml-based projects
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing pipx install llm on the reported Python 3.11/macOS ARM setup and inspect the dependency path from openai<1.0 to aiohttp-3.8.6. Investigate the aiohttp/_websocket.c build failure and the package metadata or dependency declarations involved. Done means a clean pipx installation completes without the reported wheel-build error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- build-system, cli
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 32/100