Skip to content

Docker build fails #619

@WiseBird

Description

@WiseBird

Describe the bug
Docker build fails with the next error

20.66
20.66   Backend subprocess exited when trying to invoke get_requires_for_build_wheel
20.66
20.66   Cythonizing sources
20.66   Compiling srsly/msgpack/_unpacker.pyx because it changed.
20.66   Compiling srsly/msgpack/_packer.pyx because it changed.
20.66   [1/2] Cythonizing srsly/msgpack/_packer.pyx
20.66   [2/2] Cythonizing srsly/msgpack/_unpacker.pyx
20.66
20.66   Error compiling Cython file:
20.66   ------------------------------------------------------------
20.66   ...
20.66       object PyMemoryView_GetContiguous(object obj, int buffertype, char order)
20.66
20.66   from libc.stdlib cimport *
20.66   from libc.string cimport *
20.66   from libc.limits cimport *
20.66   ctypedef unsigned long long uint64_t
20.66   ^
20.66   ------------------------------------------------------------
20.66
20.66   srsly/msgpack/_unpacker.pyx:13:0: 'uint64_t' redeclared
20.66
20.66   Error compiling Cython file:
20.66   ------------------------------------------------------------
20.66   ...
20.66   cdef extern from "Python.h":
20.66       ctypedef int int32_t
20.66       ctypedef int int64_t
20.66       ctypedef unsigned int uint32_t
20.66       ctypedef unsigned int uint64_t
20.66       ^
20.66   ------------------------------------------------------------
20.66
20.66   /tmp/tmp82ajuywo/.venv/lib/python3.9/site-packages/Cython/Includes/cpython/pyport.pxd:5:4: Previous declaration is here
20.66   Traceback (most recent call last):
20.66     File "/usr/local/poetry/venv/lib/python3.9/site-packages/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
20.66       main()
20.66     File "/usr/local/poetry/venv/lib/python3.9/site-packages/pyproject_hooks/_in_process/_in_process.py", line 335, in main
20.66       json_out['return_val'] = hook(**hook_input['kwargs'])
20.66     File "/usr/local/poetry/venv/lib/python3.9/site-packages/pyproject_hooks/_in_process/_in_process.py", line 118, in get_requires_for_build_wheel
20.66       return hook(config_settings)
20.66     File "/tmp/tmp82ajuywo/.venv/lib/python3.9/site-packages/setuptools/build_meta.py", line 325, in get_requires_for_build_wheel
20.66       return self._get_build_requires(config_settings, requirements=['wheel'])
20.66     File "/tmp/tmp82ajuywo/.venv/lib/python3.9/site-packages/setuptools/build_meta.py", line 295, in _get_build_requires
20.66       self.run_setup()
20.66     File "/tmp/tmp82ajuywo/.venv/lib/python3.9/site-packages/setuptools/build_meta.py", line 311, in run_setup
20.66       exec(code, locals())
20.66     File "<string>", line 138, in <module>
20.66     File "<string>", line 125, in setup_package
20.66     File "/tmp/tmp82ajuywo/.venv/lib/python3.9/site-packages/Cython/Build/Dependencies.py", line 1154, in cythonize
20.66       cythonize_one(*args)
20.66     File "/tmp/tmp82ajuywo/.venv/lib/python3.9/site-packages/Cython/Build/Dependencies.py", line 1321, in cythonize_one
20.66       raise CompileError(None, pyx_file)
20.66   Cython.Compiler.Errors.CompileError: srsly/msgpack/_unpacker.pyx
20.66
20.66
20.66   at /usr/local/poetry/venv/lib/python3.9/site-packages/poetry/installation/chef.py:152 in _prepare
20.66       148│
20.66       149│                 error = ChefBuildError("\n\n".join(message_parts))
20.66       150│
20.66       151│             if error is not None:
20.66     → 152│                 raise error from None
20.66       153│
20.66       154│             return path
20.66       155│
20.66       156│     def _prepare_sdist(self, archive: Path, destination: Path | None = None) -> Path:
20.66
20.66 Note: This error originates from the build backend, and is likely not a problem with poetry but with srsly (2.4.2) not supporting PEP 517 builds. You can verify this by running 'pip wheel --use-pep517 "srsly (==2.4.2) ; python_version >= "3.6""'.
20.66
------
Dockerfile:36
--------------------
  35 |     WORKDIR /app
  36 | >>> RUN poetry config virtualenvs.create false && \
  37 | >>>   poetry install --extras ${DEVICE} --no-interaction --no-ansi --no-root $(/usr/bin/test $STAGE == production && echo "--without dev,test,docs")
  38 |
--------------------
ERROR: failed to solve: process "/bin/sh -c poetry config virtualenvs.create false &&   poetry install --extras ${DEVICE} --no-interaction --no-ansi --no-root $(/usr/bin/test $STAGE == production && echo \"--without dev,test,docs\")" did not complete successfully: exit code: 1

Vesion (please complete the following information):

  • OS: MacOS Sonoma 14.0
  • Azimuth version: 2.8.0 (3408104 commit)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions