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

Failed building wheel for kiwisolver :( #144

Closed
OTonGitHub opened this issue Jun 14, 2022 · 4 comments · Fixed by #145
Closed

Failed building wheel for kiwisolver :( #144

OTonGitHub opened this issue Jun 14, 2022 · 4 comments · Fixed by #145

Comments

@OTonGitHub
Copy link

I was trying to install Matplotlib on my Mac via pip.
I am on MacOS 12.4, Have python 3.11.0b1 installed via pyenv.
I got pip version 22.1.2.

Here is the output of showing how my cli commands are aliased and versions output.
ot@OT % pyenv global && python -V && python3 -V && pip -V && pip3 -V 3.11.0b1 Python 3.11.0b1 Python 3.11.0b1 pip 22.1.2 from /Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/site-packages/pip (python 3.11) pip 22.1.2 from /Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/site-packages/pip (python 3.11)

Here is the full log I get when I run
python -m pip install --no-cache-dir -U matplotlib --prefer-binary
`ot@OT wheels % python -m pip install --no-cache-dir -U matplotlib --prefer-binary
Collecting matplotlib
Downloading matplotlib-3.5.2.tar.gz (35.2 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 35.2/35.2 MB 3.0 MB/s eta 0:00:00
Preparing metadata (setup.py) ... done
Collecting cycler>=0.10
Downloading cycler-0.11.0-py3-none-any.whl (6.4 kB)
Collecting fonttools>=4.22.0
Downloading fonttools-4.33.3-py3-none-any.whl (930 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 930.9/930.9 kB 3.2 MB/s eta 0:00:00
Collecting kiwisolver>=1.0.1
Downloading kiwisolver-1.4.3.tar.gz (96 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 97.0/97.0 kB 3.3 MB/s eta 0:00:00
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... done
Requirement already satisfied: numpy>=1.17 in /Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/site-packages (from matplotlib) (1.22.4)
Collecting packaging>=20.0
Downloading packaging-21.3-py3-none-any.whl (40 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 40.8/40.8 kB 3.2 MB/s eta 0:00:00
Collecting pillow>=6.2.0
Downloading Pillow-9.1.1.tar.gz (49.8 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 49.8/49.8 MB 3.0 MB/s eta 0:00:00
Preparing metadata (setup.py) ... done
Collecting pyparsing>=2.2.1
Downloading pyparsing-3.0.9-py3-none-any.whl (98 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 98.3/98.3 kB 1.5 MB/s eta 0:00:00
Requirement already satisfied: python-dateutil>=2.7 in /Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/site-packages (from matplotlib) (2.8.2)
Requirement already satisfied: six>=1.5 in /Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/site-packages (from python-dateutil>=2.7->matplotlib) (1.16.0)
Building wheels for collected packages: matplotlib, kiwisolver, pillow
Building wheel for matplotlib (setup.py) ... done
Created wheel for matplotlib: filename=matplotlib-3.5.2-cp311-cp311-macosx_12_0_arm64.whl size=7167296 sha256=bda7bab448dc6dd3257f64435609f910fd9f6a8564dd04ddfffc664763b422b7
Stored in directory: /private/var/folders/_6/3ksx9tjs5bg4vpm2jxkjnzrh0000gn/T/pip-ephem-wheel-cache-gp_e6tlm/wheels/0b/7b/2b/2a2af3f6b6cc1af9efbf31fb89c2867bce7b280512e4d9becc
Building wheel for kiwisolver (pyproject.toml) ... error
error: subprocess-exited-with-error

× Building wheel for kiwisolver (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [33 lines of output]
/private/var/folders/_6/3ksx9tjs5bg4vpm2jxkjnzrh0000gn/T/pip-build-env-g6knshvn/overlay/lib/python3.11/site-packages/setuptools/config/pyprojecttoml.py:102: _ExperimentalProjectMetadata: Support for project metadata in pyproject.toml is still experimental and may be removed (or change) in future releases.
warnings.warn(msg, _ExperimentalProjectMetadata)
running bdist_wheel
running build
running build_py
creating build
creating build/lib.macosx-12.4-arm64-cpython-311
creating build/lib.macosx-12.4-arm64-cpython-311/kiwisolver
copying py/kiwisolver/init.py -> build/lib.macosx-12.4-arm64-cpython-311/kiwisolver
package init file 'py/src/init.py' not found (or not a regular file)
copying py/kiwisolver/py.typed -> build/lib.macosx-12.4-arm64-cpython-311/kiwisolver
copying py/kiwisolver/_cext.pyi -> build/lib.macosx-12.4-arm64-cpython-311/kiwisolver
running build_ext
building 'kiwisolver._cext' extension
creating build/temp.macosx-12.4-arm64-cpython-311
creating build/temp.macosx-12.4-arm64-cpython-311/py
creating build/temp.macosx-12.4-arm64-cpython-311/py/src
clang -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -I/private/var/folders/_6/3ksx9tjs5bg4vpm2jxkjnzrh0000gn/T/pip-build-env-g6knshvn/overlay/lib/python3.11/site-packages/cppy/include -I. -I/Users/ot/.pyenv/versions/3.11.0b1/include/python3.11 -c py/src/constraint.cpp -o build/temp.macosx-12.4-arm64-cpython-311/py/src/constraint.o -std=c++11 -stdlib=libc++
In file included from py/src/constraint.cpp:13:
py/src/util.h:120:9: error: reinterpret_cast from 'nullptr_t' to 'const PyObject *' (aka 'const _object ') is not allowed
PyTuple_SET_ITEM( terms.get(), i, nullptr );
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/ot/.pyenv/versions/3.11.0b1/include/python3.11/cpython/tupleobject.h:35:48: note: expanded from macro 'PyTuple_SET_ITEM'
PyTuple_SET_ITEM(_PyTuple_CAST(op), index, _PyObject_CAST(value))
^~~~~~~~~~~~~~~~~~~~~
/Users/ot/.pyenv/versions/3.11.0b1/include/python3.11/object.h:107:28: note: expanded from macro '_PyObject_CAST'
#define _PyObject_CAST(op) _Py_CAST(PyObject
, (op))
^~~~~~~~~~~~~~~~~~~~~~~~~
/Users/ot/.pyenv/versions/3.11.0b1/include/python3.11/pyport.h:30:25: note: expanded from macro '_Py_CAST'
const_cast(reinterpret_cast(expr))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error 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 kiwisolver
Building wheel for pillow (setup.py) ... error
error: subprocess-exited-with-error

× python setup.py bdist_wheel did not run successfully.
│ exit code: 1
╰─> [193 lines of output]
running bdist_wheel
running build
running build_py
creating build
creating build/lib.macosx-12.4-arm64-3.11
creating build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/MpoImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageMode.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/PngImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/XbmImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/PcxImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/SunImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageFile.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/SpiderImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/TarIO.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/FitsStubImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/MpegImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/BdfFontFile.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/GribStubImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageStat.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/PixarImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/GimpPaletteFile.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageColor.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ContainerIO.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/MspImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/MicImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/_version.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImtImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/GifImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/PalmImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageQt.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageMath.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/PaletteFile.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/FontFile.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/PdfParser.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ExifTags.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageCms.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/FpxImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageChops.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/BufrStubImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/PSDraw.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/PcdImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageFilter.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageDraw2.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImagePath.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/DcxImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/init.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/JpegPresets.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/Hdf5StubImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/features.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageDraw.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/GimpGradientFile.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageWin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/IcoImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/_tkinter_finder.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/EpsImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/TgaImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageMorph.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/Jpeg2KImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/WalImageFile.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/PcfFontFile.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/BlpImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageTk.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/GbrImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageOps.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/PdfImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageShow.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageEnhance.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/WmfImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageGrab.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/WebPImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/FliImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/TiffTags.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/CurImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/_util.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/GdImageFile.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/TiffImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/IptcImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImagePalette.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/BmpImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageTransform.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/IcnsImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/McIdasImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/FitsImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/XpmImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/DdsImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageSequence.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/PyAccess.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/_binary.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/Image.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/main.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/XVThumbImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/SgiImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/PsdImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/JpegImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/ImageFont.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/PpmImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
copying src/PIL/FtexImagePlugin.py -> build/lib.macosx-12.4-arm64-3.11/PIL
running egg_info
writing src/Pillow.egg-info/PKG-INFO
writing dependency_links to src/Pillow.egg-info/dependency_links.txt
writing requirements to src/Pillow.egg-info/requires.txt
writing top-level names to src/Pillow.egg-info/top_level.txt
reading manifest file 'src/Pillow.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no files found matching '.c'
warning: no files found matching '
.h'
warning: no files found matching '.sh'
warning: no files found matching '
.txt'
warning: no previously-included files found matching '.appveyor.yml'
warning: no previously-included files found matching '.clang-format'
warning: no previously-included files found matching '.coveragerc'
warning: no previously-included files found matching '.editorconfig'
warning: no previously-included files found matching '.readthedocs.yml'
warning: no previously-included files found matching 'codecov.yml'
warning: no previously-included files matching '.git*' found anywhere in distribution
warning: no previously-included files matching '.pyc' found anywhere in distribution
warning: no previously-included files matching '
.so' found anywhere in distribution
no previously-included directories found matching '.ci'
adding license file 'LICENSE'
writing manifest file 'src/Pillow.egg-info/SOURCES.txt'
running build_ext

  The headers or library files could not be found for jpeg,
  a required dependency when compiling Pillow from source.
  
  Please see the install instructions at:
     https://pillow.readthedocs.io/en/latest/installation.html
  
  Traceback (most recent call last):
    File "/private/var/folders/_6/3ksx9tjs5bg4vpm2jxkjnzrh0000gn/T/pip-install-i2nv2g7e/pillow_4d25ff4f8e6a42b39efbeb56a6005015/setup.py", line 989, in <module>
      setup(
      ^^^^^^
    File "/Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/site-packages/setuptools/__init__.py", line 153, in setup
      return distutils.core.setup(**attrs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/distutils/core.py", line 148, in setup
      dist.run_commands()
      ^^^^^^^^^^^^^^^^^^^
    File "/Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/distutils/dist.py", line 966, in run_commands
      self.run_command(cmd)
      ^^^^^^^^^^^^^^^^^^^^^
    File "/Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/distutils/dist.py", line 985, in run_command
      cmd_obj.run()
      ^^^^^^^^^^^^^
    File "/Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/site-packages/wheel/bdist_wheel.py", line 299, in run
      self.run_command('build')
      ^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/distutils/cmd.py", line 313, in run_command
      self.distribution.run_command(command)
      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/distutils/dist.py", line 985, in run_command
      cmd_obj.run()
      ^^^^^^^^^^^^^
    File "/Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/distutils/command/build.py", line 135, in run
      self.run_command(cmd_name)
      ^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/distutils/cmd.py", line 313, in run_command
      self.distribution.run_command(command)
      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/distutils/dist.py", line 985, in run_command
      cmd_obj.run()
      ^^^^^^^^^^^^^
    File "/Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/site-packages/setuptools/command/build_ext.py", line 79, in run
      _build_ext.run(self)
      ^^^^^^^^^^^^^^^^^^^^
    File "/Users/ot/.pyenv/versions/3.11.0b1/lib/python3.11/distutils/command/build_ext.py", line 340, in run
      self.build_extensions()
      ^^^^^^^^^^^^^^^^^^^^^^^
    File "/private/var/folders/_6/3ksx9tjs5bg4vpm2jxkjnzrh0000gn/T/pip-install-i2nv2g7e/pillow_4d25ff4f8e6a42b39efbeb56a6005015/setup.py", line 802, in build_extensions
      if not getattr(feature, f) and feature.require(f):
                                     ^^^^^^^^^^^^^^^^^^
  RequiredDependencyException: jpeg
  
  During handling of the above exception, another exception occurred:
  
  Traceback (most recent call last):
    File "<string>", line 2, in <module>
    File "<pip-setuptools-caller>", line 34, in <module>
    File "/private/var/folders/_6/3ksx9tjs5bg4vpm2jxkjnzrh0000gn/T/pip-install-i2nv2g7e/pillow_4d25ff4f8e6a42b39efbeb56a6005015/setup.py", line 1009, in <module>
      raise RequiredDependencyException(msg)
      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  RequiredDependencyException:
  
  The headers or library files could not be found for jpeg,
  a required dependency when compiling Pillow from source.
  
  Please see the install instructions at:
     https://pillow.readthedocs.io/en/latest/installation.html
  
  
  [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for pillow
Running setup.py clean for pillow
Successfully built matplotlib
Failed to build kiwisolver pillow
ERROR: Could not build wheels for kiwisolver, which is required to install pyproject.toml-based projects
`

If I try to install just kiwisolver by running
python -m pip install kiwisolver --no-cache-dir
I get the following output: (pretty much the same thing)
`ot@OT wheels % python -m pip install kiwisolver --no-cache-dir
Collecting kiwisolver
Downloading kiwisolver-1.4.3.tar.gz (96 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 97.0/97.0 kB 1.3 MB/s eta 0:00:00
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... done
Building wheels for collected packages: kiwisolver
Building wheel for kiwisolver (pyproject.toml) ... error
error: subprocess-exited-with-error

× Building wheel for kiwisolver (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [33 lines of output]
/private/var/folders/_6/3ksx9tjs5bg4vpm2jxkjnzrh0000gn/T/pip-build-env-6x1nz7yk/overlay/lib/python3.11/site-packages/setuptools/config/pyprojecttoml.py:102: _ExperimentalProjectMetadata: Support for project metadata in pyproject.toml is still experimental and may be removed (or change) in future releases.
warnings.warn(msg, _ExperimentalProjectMetadata)
running bdist_wheel
running build
running build_py
creating build
creating build/lib.macosx-12.4-arm64-cpython-311
creating build/lib.macosx-12.4-arm64-cpython-311/kiwisolver
copying py/kiwisolver/init.py -> build/lib.macosx-12.4-arm64-cpython-311/kiwisolver
package init file 'py/src/init.py' not found (or not a regular file)
copying py/kiwisolver/py.typed -> build/lib.macosx-12.4-arm64-cpython-311/kiwisolver
copying py/kiwisolver/_cext.pyi -> build/lib.macosx-12.4-arm64-cpython-311/kiwisolver
running build_ext
building 'kiwisolver._cext' extension
creating build/temp.macosx-12.4-arm64-cpython-311
creating build/temp.macosx-12.4-arm64-cpython-311/py
creating build/temp.macosx-12.4-arm64-cpython-311/py/src
clang -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -I/private/var/folders/_6/3ksx9tjs5bg4vpm2jxkjnzrh0000gn/T/pip-build-env-6x1nz7yk/overlay/lib/python3.11/site-packages/cppy/include -I. -I/Users/ot/.pyenv/versions/3.11.0b1/include/python3.11 -c py/src/constraint.cpp -o build/temp.macosx-12.4-arm64-cpython-311/py/src/constraint.o -std=c++11 -stdlib=libc++
In file included from py/src/constraint.cpp:13:
py/src/util.h:120:9: error: reinterpret_cast from 'nullptr_t' to 'const PyObject *' (aka 'const _object ') is not allowed
PyTuple_SET_ITEM( terms.get(), i, nullptr );
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/ot/.pyenv/versions/3.11.0b1/include/python3.11/cpython/tupleobject.h:35:48: note: expanded from macro 'PyTuple_SET_ITEM'
PyTuple_SET_ITEM(_PyTuple_CAST(op), index, _PyObject_CAST(value))
^~~~~~~~~~~~~~~~~~~~~
/Users/ot/.pyenv/versions/3.11.0b1/include/python3.11/object.h:107:28: note: expanded from macro '_PyObject_CAST'
#define _PyObject_CAST(op) _Py_CAST(PyObject
, (op))
^~~~~~~~~~~~~~~~~~~~~~~~~
/Users/ot/.pyenv/versions/3.11.0b1/include/python3.11/pyport.h:30:25: note: expanded from macro '_Py_CAST'
const_cast(reinterpret_cast(expr))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error 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 kiwisolver
Failed to build kiwisolver
ERROR: Could not build wheels for kiwisolver, which is required to install pyproject.toml-based projects
`
any help is kindly appreciated, I am not a programmer, so I apologise in advance if the issue seems irrelevant or is presented badly, I think I gave all the necessary information though. Let me know you need any further info, I will follow up when I get time.

@MatthieuDartiailh
Copy link
Member

Thanks for the report. I switched to nullptr because it solved some build failures and I am surprised CIs did not catch this one.

I may not have time to look into this before the week-end but I will do my best to fix it ASAP.

@OTonGitHub
Copy link
Author

could this be a problem on my side because I was able to successfully install it from building the wheel from source and installing it from there. Like this.

ot@OT kiwisolver-1.3.2 % python -m pip -U install . Processing /Users/ot/Downloads/kiwi/kiwisolver-1.3.2 Preparing metadata (setup.py) ... done Building wheels for collected packages: kiwisolver Building wheel for kiwisolver (setup.py) ... done Created wheel for kiwisolver: filename=kiwisolver-1.3.2-cp311-cp311-macosx_12_0_arm64.whl size=56579 sha256=f5ea5d113b96ac1322679851bcfa727edf422f0ffff3869be1f5341c704d8205 Stored in directory: /Users/ot/Library/Caches/pip/wheels/29/1f/4c/5a586c2d07fe1753b73d0e01b1b12f452999e1eac8573ee7c2 Successfully built kiwisolver Installing collected packages: kiwisolver Successfully installed kiwisolver-1.3.2

And confirmed installation here
ot@OT Pillow-9.1.1 % pip list | grep kiwisolver kiwisolver 1.3.2

@MatthieuDartiailh
Copy link
Member

The beta 4 scheduled for tomorrow should contain a fix that will allow me to revert the changes causing the issue you saw. I will prepare a PR and if you can test it with beta 4 (since I do not have access to an ARM Mac) it would be great. I will try to make a release over the week-end if everything works.

@OTonGitHub
Copy link
Author

Sure of course. I had some other libraries break as well, presumably because 3.11 is in beta status, But ill test it as soon as beta 4 is out. The swift handling is really appreciated 👍

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

Successfully merging a pull request may close this issue.

2 participants