79208940

Date: 2024-11-20 21:00:31
Score: 2
Natty:
Report link

But it's hard to remove a library, because I can't tell whether a library listed in environment.yml was added by explicit installation or whether it was added as a dependency for a different package that I installed.

This is addressed in Hami's link (https://stackoverflow.com/a/26101973/633093). If you are using the latest conda with mamba solver, conda repoquery whoneeds -t packagename can be used to identify the exact dependencies.

How do I specify project dependencies separate from Conda environments?

To address the main question, environment.yml is still widely used today for maintaining conda environments (not automated but conda tooling has improved a lot). For maintaining project dependencies, poetry is an option: see this related question: Does it make sense to use Conda + Poetry?

Reasons:
  • Blacklisted phrase (1): How do I
  • Blacklisted phrase (1): stackoverflow
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Ends in question mark (2):
  • High reputation (-1):
Posted by: prusswan