Hello,
when I do “balena push XXX” to push screenly on my balena project in my dashboard, the console gives me after a long way, in my opinion in the near of the end, the following error:
[Error] Some services failed to build:
[Error] Service: srly-ose-server
[Error] Error: The command ‘/bin/sh -c pip install --no-cache-dir -r /tmp/requirements.txt’ returned a non-zero code: 1
[Error] Service: srly-ose-celery
[Error] Error: The command ‘/bin/sh -c pip install --no-cache-dir -r /tmp/requirements.txt’ returned a non-zero code: 1
[Info] Built on arm04
[Error] Not deploying release.
Remote build failed
What can I do, where is my error?
Before this, I also get this error very at the beginning:
[srly-ose-viewer] requests 2.24.0 has requirement urllib3!=1.25.0,!=1.25.1,<1.26,>=1.21.1, but you’ll have urllib3 1.26.5 which is incompatible.
The version of urllib needs to be less than 1.26 and greater than 1.21. Somewhere else in the project (either in the requirements.txt file or Dockerfile), something installed version 1.26.5 of urllib which conflicts with the requests requirements. Find a version of urllib that is supported by all the other packages that require it and pin to that specific version in your requirements.txt file before installing requests and the others.
Hi Jack, would be able to give us a short how-to? I’m as a noob have the same problem and unfortunately I’m not aware of how to solve it. Thanks in advance.
Edit: I was able to solve by using older versions. I changed in requirements.txt:
celery==4.4.7 (was 5.x.x)
requests[security]==2.20.0 (was 2.4.x)
urllib3==1.24.0 (was 1.26.5)
also the requirements.viewer.txt:
requests[security]==2.20.0 (was 2.4.x)
urllib3==1.24.0 (was 1.26.5)
Hi @kadowa-medien as you mentioned you’re a beginner, lending a tip for next time you run into dependency issues, though I’m not sure if this is a best practice.
I usually omit all version specifications in my requirements.txt file to get a successful build, then replace all versions back in requirements.txt after running pip freeze. I also find that versioning from the package manager (i.e. in the install_packages section of your Dockerfile) leads to more robust and faster builds. Hope this helps!
Hi,
I solved it like this:
firstly, install pip.
Then go to terminal: “pip install urllib3==1.25.5” and “pip install celery==4.4.7” i think it was.
Then go to the screenly-ose-master folder, and change the versions in requirements/requirements.txt to the installed versions. Now you can use balena push normally.
can you please share the resources and repositories that you use to create the screenly application?
Can you please share the dockerfile for the image build steps?
Do you use a docker-compose file to specify the services and can you share it?
We would like to help you to automate these steps, as the mentioned solution should be able to be solved in the dockerfile.