I am getting a Error: ‘package is not compatible with current python version’. I want to run my code of the local chatbot (using Python 3.10.4, Langchain, Ollama, chormadb, streamlit) in a docker container using windows 10. My docker file looks like below.
# Use the official Python image from the Docker Hub
FROM python:3.10.4-slim
# Set the working directory in the container
WORKDIR /app
# Copy the current directory contents into the container at /app
COPY . /app
# Install system dependencies
RUN apt-get update && apt-get install -y
build-essential
libpoppler-cpp-dev
tesseract-ocr
tesseract-ocr-eng
libtesseract-dev
pkg-config
poppler-utils
&& rm -rf /var/lib/apt/lists/*
# Copy the requirements.txt file into the container
COPY rewuirements.txt ./
RUN pip install --no-cache-dir -r rewuirements.txt
# Expose the port Streamlit will run on
EXPOSE 8501
# Run the Streamlit app
CMD ["streamlit", "run", "rag.py"]
However, everytime I run the file to build the docker container. I am facing an error saying that My ABC
package is not compatible for current python version. On the other side, I check the Package ABC by pip show ABC
outside the docker container (and inside my python virtual enviornment), it shows that Package ABC
is already there.
Could anyone please explain me what is the problem and how to solve it?