Streamlit and ContainDS ImportError: Failed to initialize: Bad git executable

  docker, python, streamlit

am trying to run a simple Streamlit app, using ContainDS (https://containds.com/) on a Macbook.
The objective is to export a file and use ContainDS to easily share a dashboard with a client.

The project folder, placed on my desktop, has the following structure:

project_1234:
         ---- streamlit_app.py
         ---- Additional_scripts:
                               ---- ... .py

However, as soon as I launch Docker and ContainDS, instantiate a streamlit-single image, specify folder "project_1234" and click on create, the following error is displayed :

Traceback (most recent call last):
  File "/opt/conda/lib/python3.8/site-packages/git/__init__.py", line 83, in <module>
    refresh()
  File "/opt/conda/lib/python3.8/site-packages/git/__init__.py", line 73, in refresh
    if not Git.refresh(path=path):
...

ImportError:
Bad git executable.

The git executable must be specified in one of the following ways:   
- be included in your $PATH   
- be set via $GIT_PYTHON_GIT_EXECUTABLE   
- explicitly set via git.refresh()

Furthermore, even if I run a simple Streamlit intro.py script, the same error is reported;
for your reference, I’m using Python 3.7.9 on my OS, based on anaconda.

How can I solve this issue and share the app with my client?

Source: Docker Questions

LEAVE A COMMENT