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

Docker build: opencv-python-headless fails #983

Closed
bertsky opened this issue Feb 14, 2023 · 3 comments
Closed

Docker build: opencv-python-headless fails #983

bertsky opened this issue Feb 14, 2023 · 3 comments

Comments

@bertsky
Copy link
Collaborator

bertsky commented Feb 14, 2023

Our last Docker release is now 9 months old. It seems there is a persistent error around the OpenCV Build:

ERROR: Failed building wheel for opencv-python-headless

Perhaps Python 3.6 is not supported anymore (no wheels on PyPI)? Or do we need more system dependencies now?

@bertsky
Copy link
Collaborator Author

bertsky commented Feb 17, 2023

@kba your CI config change still does not work on the Scrutinizer chain – it for some reason needs sudo for make deps-ubuntu. Also, on master we fail to deploy awkwardly:

/bin/sh: 1: pip: not found
The command '/bin/sh -c apt-get update && apt-get -y install software-properties-common     && apt-get update && apt-get -y install         ca-certificates         python3-dev         python3-pip         gcc         make         wget         time         curl         sudo         git     && make deps-ubuntu     && pip install --upgrade pip setuptools     && make install     && apt-get remove -y gcc     && apt-get autoremove -y     && $FIXUP     && rm -rf /build-ocrd' returned a non-zero code: 127
Makefile:217: recipe for target 'docker-cuda' failed

So make docker runs through, but docker-cuda does not.

Regarding the original error reported here – that seems to have been specific to 3.6 (and I believe it would suffice to do a simple pip install -U pip first, to get pip install cmake working; so we could even reactivate our 3.6 CI...)

@bertsky bertsky mentioned this issue Feb 17, 2023
@mikegerber
Copy link
Contributor

I've been using this sometimes:

pip3 install -U pip
pip3 install --only-binary :all: opencv-python-headless

This installs an older opencv-python-headless, but from a wheel and without the compile time. I'd recommend always testing anything involving opencv-python-headless, we had some tricky issues with it.

@bertsky
Copy link
Collaborator Author

bertsky commented Jun 4, 2023

We did introduce a workaround in ocrd_all earlier to avoid source compilation (which effectively downgrades, but also speeds up). This warrants closing – also, 3.6 is not officially supported anymore.

@bertsky bertsky closed this as completed Jun 4, 2023
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

No branches or pull requests

2 participants