-
Notifications
You must be signed in to change notification settings - Fork 950
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
docs: add that uv sync and install include dev dependencies by default #10357
docs: add that uv sync and install include dev dependencies by default #10357
Conversation
* Previously had uv python install, then uv sync --all-extras --dev * If we are going to use sync for dev dependencies, then the install step is unneccessary
inclusion or exclusion of its dependencies. Additionally, the `dev` group is | ||
[synced by default](#default-groups). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We already say the dev
group is synced by default here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When I read this - I wasn't aware that "sync" meant the same thing as install, happy to close though if others didn't have this misunderstanding
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't have a top level uv install
command. Perhaps we could clarify what sync
does, but I think it's mentioned elsewhere?
@@ -591,6 +594,14 @@ The `dev` group is special-cased; there are `--dev`, `--only-dev`, and `--no-dev | |||
inclusion or exclusion of its dependencies. Additionally, the `dev` group is | |||
[synced by default](#default-groups). | |||
|
|||
To install dependencies you can use install or sync | |||
```console | |||
$ uv pip install |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This command wouldn't work as-written.
I'm not sure the others make sense here either, as this section is specifically about the dev
group and the rest are covered elsewhere.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Was attempting to add a couple mentinons explaining how the dependency groups work, revising the command
Yeah sorry, but I'm not sure this is an improvement. Feel free to open an issue for discussion on the point of confusion if you want. |
To install dependencies you can use install or sync | ||
|
||
```console | ||
$ uv python install |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using uv python install
won't include any groups — it just installs a Python version.
|
||
```console | ||
$ uv python install | ||
$ uv sync --all-extras # installs all optional dependencies |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Extras are distinct from groups and have a separate section in these docs
$ uv sync --group lint # installs dependency group lint | ||
$ uv sync --only-group lint # installs ONLY dependency group lint |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These two would make more sense in the following "Dependency groups" section, e.g., after
Once groups are defined, the
--group
,--only-group
, and--no-group
options can be used to
include or exclude their dependencies.
Summary
Test Plan