Skip to content

Facing error when try to Install unstructured[pdf] when it reached stage opencv-python in python:3.11-alpine docker image #919

@hteeyeoh

Description

@hteeyeoh

Expected behaviour

Successfully installed unstructured[pdf] in python3.11-alpine

Actual behaviour

Collecting opencv-python==4.6.0.66 (from unstructured-inference->unstructured==0.10.16->-r /requirements.txt (line 4))
211.2   Downloading opencv-python-4.6.0.66.tar.gz (90.3 MB)
217.0      ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 90.3/90.3 MB 81.4 MB/s eta 0:00:00
219.7   Installing build dependencies: started
220.6   Installing build dependencies: finished with status 'error'
220.6   error: subprocess-exited-with-error
220.6
220.6   × pip subprocess to install build dependencies did not run successfully.
220.6   │ exit code: 1
220.6   ╰─> [25 lines of output]
220.6       Ignoring numpy: markers 'python_version == "3.6" and platform_machine != "aarch64" and platform_machine != "arm64"' don't match your environment
220.6       Ignoring numpy: markers 'python_version == "3.7" and platform_machine != "aarch64" and platform_machine != "arm64"' don't match your environment
220.6       Ignoring numpy: markers 'python_version == "3.8" and platform_machine != "aarch64" and platform_machine != "arm64"' don't match your environment
220.6       Ignoring numpy: markers 'python_version <= "3.9" and sys_platform == "linux" and platform_machine == "aarch64"' don't match your environment
220.6       Ignoring numpy: markers 'python_version <= "3.9" and sys_platform == "darwin" and platform_machine == "arm64"' don't match your environment
220.6       Ignoring numpy: markers 'python_version == "3.9" and platform_machine != "aarch64" and platform_machine != "arm64"' don't match your environment
220.6       Collecting setuptools==59.2.0
220.6         Using cached setuptools-59.2.0-py3-none-any.whl (952 kB)
220.6       Collecting wheel==0.37.0
220.6         Using cached wheel-0.37.0-py2.py3-none-any.whl (35 kB)
220.6       Collecting cmake>=3.1
220.6         Obtaining dependency information for cmake>=3.1 from https://files.pythonhosted.org/packages/bd/c9/3702abd06bbd773961b359e530a57db4d78fdb042ecb7b52c505564fdde2/cmake-3.27.7-py2.py3-none-musllinux_1_1_x86_64.whl.metadata
220.6         Using cached cmake-3.27.7-py2.py3-none-musllinux_1_1_x86_64.whl.metadata (6.7 kB)
220.6       Collecting pip
220.6         Obtaining dependency information for pip from https://files.pythonhosted.org/packages/47/6a/453160888fab7c6a432a6e25f8afe6256d0d9f2cbd25971021da6491d899/pip-23.3.1-py3-none-any.whl.metadata
220.6         Using cached pip-23.3.1-py3-none-any.whl.metadata (3.5 kB)
220.6       Collecting scikit-build>=0.13.2
220.6         Obtaining dependency information for scikit-build>=0.13.2 from https://files.pythonhosted.org/packages/fa/af/b3ef8fe0bb96bf7308e1f9d196fc069f0c75d9c74cfaad851e418cc704f4/scikit_build-0.17.6-py3-none-any.whl.metadata
220.6         Using cached scikit_build-0.17.6-py3-none-any.whl.metadata (14 kB)
220.6       ERROR: Ignored the following versions that require a different python version: 1.21.2 Requires-Python >=3.7,<3.11; 1.21.3 Requires-Python >=3.7,<3.11; 1.21.4 Requires-Python >=3.7,<3.11; 1.21.5 Requires-Python >=3.7,<3.11; 1.21.6 Requires-Python >=3.7,<3.11
220.6       ERROR: Could not find a version that satisfies the requirement numpy==1.21.2 (from versions: 1.3.0, 1.4.1, 1.5.0, 1.5.1, 1.6.0, 1.6.1, 1.6.2, 1.7.0, 1.7.1, 1.7.2, 1.8.0, 1.8.1, 1.8.2, 1.9.0, 1.9.1, 1.9.2, 1.9.3, 1.10.0.post2, 1.10.1, 1.10.2, 1.10.4, 1.11.0, 1.11.1, 1.11.2, 1.11.3, 1.12.0, 1.12.1, 1.13.0, 1.13.1, 1.13.3, 1.14.0, 1.14.1, 1.14.2, 1.14.3, 1.14.4, 1.14.5, 1.14.6, 1.15.0, 1.15.1, 1.15.2, 1.15.3, 1.15.4, 1.16.0, 1.16.1, 1.16.2, 1.16.3, 1.16.4, 1.16.5, 1.16.6, 1.17.0, 1.17.1, 1.17.2, 1.17.3, 1.17.4, 1.17.5, 1.18.0, 1.18.1, 1.18.2, 1.18.3, 1.18.4, 1.18.5, 1.19.0, 1.19.1, 1.19.2, 1.19.3, 1.19.4, 1.19.5, 1.20.0, 1.20.1, 1.20.2, 1.20.3, 1.21.0, 1.21.1, 1.22.0, 1.22.1, 1.22.2, 1.22.3, 1.22.4, 1.23.0rc1, 1.23.0rc2, 1.23.0rc3, 1.23.0, 1.23.1, 1.23.2, 1.23.3, 1.23.4, 1.23.5, 1.24.0rc1, 1.24.0rc2, 1.24.0, 1.24.1, 1.24.2, 1.24.3, 1.24.4, 1.25.0rc1, 1.25.0, 1.25.1, 1.25.2, 1.26.0b1, 1.26.0rc1, 1.26.0, 1.26.1, 1.26.2)
220.6       ERROR: No matching distribution found for numpy==1.21.2
220.6
220.6       [notice] A new release of pip is available: 23.2.1 -> 23.3.1
220.6       [notice] To update, run: pip install --upgrade pip
220.6       [end of output]
220.6
220.6   note: This error originates from a subprocess, and is likely not a problem with pip.
220.6 error: subprocess-exited-with-error
220.6
220.6 × pip subprocess to install build dependencies did not run successfully.
220.6 │ exit code: 1
220.6 ╰─> See above for output.
220.6
220.6 note: This error originates from a subprocess, and is likely not a problem with pip.
220.7
220.7 [notice] A new release of pip is available: 23.2.1 -> 23.3.1
220.7 [notice] To update, run: pip install --upgrade pip

Dockerfile:10

8 |
9 | COPY requirements.txt /
10 | >>> RUN pip install --no-cache-dir -r /requirements.txt

Steps to reproduce

use python:3.11-alpine from docker image hub then install unstructured[pdf]

  • example code
  • operating system
  • architecture (e.g. x86)
  • opencv-python version
Issue submission checklist
  • This is not a generic OpenCV usage question (looking for help for coding, other usage questions, homework etc.)
  • I have read the README of this repository and understand that this repository provides only an automated build toolchain for OpenCV Python packages (there is no actual OpenCV code here)
  • The issue is related to the build scripts in this repository, to the pre-built binaries or is a feature request (such as "please enable this additional dependency")
  • I'm using the latest version of opencv-python

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions