Skip to content

Any best practice to manage lock file for dev-dependencies? #2783

Answered by frostming
huxuan asked this question in Q&A
Discussion options

You must be logged in to vote

We need to classify development tools into several categories:

  1. Can run independently without installing the project itself, or purely static analysis, such as ruff, pre-commit, flake8.
  2. Semi-independent tools, may require installation of the project itself or some additional dependencies, such as mypy.
  3. Need to run completely in the project environment, such as pytest.

From my personal habits, if you use pre-commit, you can install all type 1 with pre-commit, and don't specify them in dev-dependencies, except for pre-commit. But if you don't want to involve pre-commit, since type 1s run on their own and shouldn't have anything to do with other tools, there is no point locking them togethe…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@huxuan
Comment options

Answer selected by huxuan
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants