skip to Main Content

I am trying to balena push a Dockerfile. After several adjustments of my code, it still comes with error and unable to be pushed. My code is shown:

 FROM balenalib/fincm3-debian-python:latest

# RUN install_packages git

RUN apt-get update 
RUN apt-get install python -y
        && apt-get install python3-pip -y
RUN apt-get install libportaudio0 libportaudio2 libportaudiocpp0 portaudio19-dev -y 
RUN pip3 install pyaudio numpy matplotlib 
             scipy librosa

# Set our working directory
WORKDIR /usr/src/app

COPY Recorder.py /usr/src/app

# Recorder.py will run when the container starts up on the device
CMD ["python","/usr/src/app/Recorder.py"]

And the error :

Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-xtrlkujj/pyaudio/

2

Answers


  1. Try run first:

    pip3 install --upgrade setuptools
    

    to make sure you have the recent version from the Setuptools package. That sometimes fixes that problem.

    And if pip needs setup tools to work. So if you don’t have it you need to install it with

    apt-get install python3-setuptools
    
    Login or Signup to reply.
  2. $ pip3 --upgrade setuptools
    
    Usage:   
      pip3 <command> [options]
    
    no such option: --upgrade
    

    Then I use this from this web

    $ sudo apt install python3-pyqt5

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search