Skip to content

[BUG] setup.py build fails with python 3.10 #32

Closed

Description

@heirecka

OS version:
Exherbo Linux (rolling)

Python3 version (python3 -V -V):
Python 3.10.0 (default, Oct 16 2021, 00:16:14) [GCC 11.2.0]

Steps to reproduce:

  1. python3.10 -B setup.py build

Actual result:

 /var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6 /var/tmp/paludis/build/dev-python-frozendict-2.0.6/work
pushd /var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6
python3.10 -B setup.py build
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.10
creating build/lib.linux-x86_64-3.10/frozendict
copying frozendict/core.py -> build/lib.linux-x86_64-3.10/frozendict
copying frozendict/__init__.py -> build/lib.linux-x86_64-3.10/frozendict
copying frozendict/VERSION -> build/lib.linux-x86_64-3.10/frozendict
running build_ext
building 'frozendict._frozendict' extension
creating build/temp.linux-x86_64-3.10
creating build/temp.linux-x86_64-3.10/var
creating build/temp.linux-x86_64-3.10/var/tmp
creating build/temp.linux-x86_64-3.10/var/tmp/paludis
creating build/temp.linux-x86_64-3.10/var/tmp/paludis/build
creating build/temp.linux-x86_64-3.10/var/tmp/paludis/build/dev-python-frozendict-2.0.6
creating build/temp.linux-x86_64-3.10/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work
creating build/temp.linux-x86_64-3.10/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS
creating build/temp.linux-x86_64-3.10/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10
creating build/temp.linux-x86_64-3.10/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6
creating build/temp.linux-x86_64-3.10/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6/frozendict
creating build/temp.linux-x86_64-3.10/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6/frozendict/src
creating build/temp.linux-x86_64-3.10/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6/frozendict/src/3_10
creating build/temp.linux-x86_64-3.10/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6/frozendict/src/3_10/cpython_src
creating build/temp.linux-x86_64-3.10/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6/frozendict/src/3_10/cpython_src/Objects
x86_64-pc-linux-gnu-cc -Wno-unused-result -Wsign-compare -DNDEBUG -fwrapv -march=native -O2 -pipe -march=native -O2 -pipe -march=native -O2 -pipe -march=native -O2 -pipe -fPIC -I/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6/frozendict/src/3_10/Include -I/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6/frozendict/src/3_10/cpython_src/Include -I/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6/frozendict/src/3_10/cpython_src/Include/internal -I/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6/frozendict/src/3_10/cpython_src/Objects -I/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6/frozendict/src/3_10/cpython_src/Objects/stringlib -I/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6/frozendict/src/3_10/cpython_src/Objects/clinic -I/usr/include/python3.10 -c /var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6/frozendict/src/3_10/cpython_src/Objects/dictobject.c -o build/temp.linux-x86_64-3.10/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6/frozendict/src/3_10/cpython_src/Objects/dictobject.o -DPY_SSIZE_T_CLEAN -DPy_BUILD_CORE
warning: build_py: byte-compiling is disabled, skipping.

In file included from /var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6/frozendict/src/3_10/cpython_src/Objects/dictobject.c:113:
/var/tmp/paludis/build/dev-python-frozendict-2.0.6/work/PYTHON_ABIS/3.10/frozendict-2.0.6/frozendict/src/3_10/cpython_src/Include/Python.h:72:10: fatal error: pytime.h: No such file or directory
   72 | #include "pytime.h"
      |          ^~~~~~~~~~
compilation terminated.
error: command '/usr/bin/x86_64-pc-linux-gnu-cc' failed with exit code 1

I suppose this might be due to the move of pytime.h from ../include/python to ../include/python/cpython (python/cpython#23988)

Activity

  1. lurch commented on Oct 22, 2021

    @lurch
    Contributor

    @Marco-Sulla Perhaps it's worth thinking about setting up a CI build? (to check that frozendict continues to build with all supported versions of Python)

  2. Marco-Sulla commented on Oct 22, 2021

    @Marco-Sulla
    Owner

    It should be fixed now.

  3. heirecka commented on Oct 22, 2021

    @heirecka
    Author

    I can confirm, thanks!

  4. Marco-Sulla commented on Oct 23, 2021

    @Marco-Sulla
    Owner

    @Marco-Sulla Perhaps it's worth thinking about setting up a CI build? (to check that frozendict continues to build with all supported versions of Python)

    Are you offering as a volunteer to maintain such a system?

  5. lurch commented on Oct 24, 2021

    @lurch
    Contributor

    Are you offering as a volunteer to maintain such a system?

    Nope, sorry. I've seen https://docs.github.com/actions/automating-builds-and-tests/building-and-testing-nodejs-or-python?langId=py used on other projects (which seems to already do "most of the hard work"?), but I've never set that up myself. It was just a suggestion.

  6. Marco-Sulla commented on Oct 24, 2021

    @Marco-Sulla
    Owner

    It's interesting, thank you. When I'll do a change to frozendict or coold (more probably coold), I'll setup such a system.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions