Alternatives for managing dependencies

Greetings, and thanks for all the hard work bringing this feature!

Do you plan to include alternative ways to specify dependencies, e.g, using Poetry with a poetry.lock file or directly a dockerfile? Right now the requirements.txt works perfect (in my case) when starting a new project, but existing projects that already have a different workflow for managing dependencies can be hard to change.

1 Like

We’re definitely planning on doing this!

Our plan is to support:

  • requirements.txt
  • Pipfile.lock
  • poetry.lock

What kind of support would you like for Dockerfiles?

In the short term, you can use tools like dephell to convert existing formats to requirements.txt.

1 Like

Hey, thanks. From your list I think everything I have in mind right now is covered.

Reasons for using docker would include, for example, that sometimes I mount one package in the site-packages folder to be able to import them freely in other code, mostly since streamlit cannot be run from a module a la streamlit run -m mymodule so it is kind of cumbersome to have deeply nested packages.

Docker volumes allow me to have whatever folder structure I want in my source code but present a different folder structure in runtime to streamlit so that my own dependencies are solved. I’m probably doing something wrong in this case…

Anyway, I’ve been using Poetry but just checked dephell and I’m seriously considering moving. Thanks for the suggestion!!

1 Like