Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request] Support [tool.conda-lock.dev-dependencies] section in pyproject.toml #162

Open
wesleykendall opened this issue Mar 7, 2022 · 3 comments
Labels
enhancement New feature or request

Comments

@wesleykendall
Copy link

wesleykendall commented Mar 7, 2022

The [tool.conda-lock.dependencies] section in pyproject.toml allows one to specify Conda-only dependencies that aren't available via pip. I propose a [tool.conda-lock.dev-dependencies] section for development dependencies only available via Conda.

For example, consider that you want to install git at the latest version as a development dependency but not have this be part of your production dependencies. This is a current requirement of my company since we use newer features in git for our development.

Furthermore, I'm writing a script to generate a meta.yaml (conda-build) using conda-lock. This would help me avoid pulling in git as a dependency of my Conda package when other users install it.

If the authors like this feature suggestion, let me know how trivial it might be to add it and where is the best place for me to look in the code. I'd be happy to try to open a PR. Also open to other ways to achieve this.

@wesleykendall wesleykendall changed the title Feature request: Support [tool.conda-lock.dev-dependencies] section in pyproject.toml Feature equest] Support [tool.conda-lock.dev-dependencies] section in pyproject.toml Mar 7, 2022
@wesleykendall wesleykendall changed the title Feature equest] Support [tool.conda-lock.dev-dependencies] section in pyproject.toml [Feature Request] Support [tool.conda-lock.dev-dependencies] section in pyproject.toml Mar 7, 2022
@mariusvniekerk
Copy link
Collaborator

probably in keeping with the structure of pep621 pyproject-toml files

[tool.conda-lock.optional-dependencies]
dev = ["git"]
someothercategory = ["another dep"]

@mariusvniekerk mariusvniekerk added the enhancement New feature or request label Mar 7, 2022
@wesleykendall
Copy link
Author

@mariusvniekerk My understanding of optional dependencies after reading pep621 are that they are optional production dependencies. For example, the pip_support optional dependency for conda-lock.

git would only be for development/CI purposes and never pulled into a production install, which is effectively how poetry.dev-dependencies works.

Hope that makes sense. Are you able to point me to the exact place where conda-lock parses the tool.poetry.dev-dependencies section? It might make more sense if I can open a quick PR to illustrate

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants