Make some edits to the workspace concept documentation#6223
Merged
charliermarsh merged 1 commit intomainfrom Aug 19, 2024
Merged
Make some edits to the workspace concept documentation#6223charliermarsh merged 1 commit intomainfrom
charliermarsh merged 1 commit intomainfrom
Conversation
zanieb
reviewed
Aug 19, 2024
|
|
||
| ## When (not) to use workspaces | ||
| In a workspace, each package defines its own `pyproject.toml`, but the workspace shares a single | ||
| lockfile, ensuring that the workspace operates with a consistent set of dependencies. |
Member
There was a problem hiding this comment.
This seems vaguely conflicting with the above
distinct packages with independent dependencies.
Maybe we should say "independent requirements" above? or "consistent set of dependency versions" here? I'm not sure.
zanieb
reviewed
Aug 19, 2024
docs/concepts/workspaces.md
Outdated
| has a performance-critical subroutine implemented in a native language. | ||
| As such, `uv lock` operates on the entire workspace at once, while `uv run` and `uv sync` operate on | ||
| the workspace root by default, though both accept a `--package` argument, allowing you to run a | ||
| command _in_ any workspace member _from_ any workspace directory. |
Member
There was a problem hiding this comment.
Perhaps "in a particular workspace member"?
zanieb
reviewed
Aug 19, 2024
| Currently, workspace don't properly support different members having different `requires-python` | ||
| values, we apply the highest of all `requires-python` lower bounds to the entire workspace. You need | ||
| to use a `uv pip` to install individual member in an older virtual environment. | ||
| To create a workspace, add a `tool.uv.workspace` table to a `pyproject.toml`, which will implicitly |
Member
There was a problem hiding this comment.
We could also suggest in a !!! tip that uv init child in a project will do this for you.
zanieb
reviewed
Aug 19, 2024
docs/concepts/workspaces.md
Outdated
Comment on lines
36
to
37
| Every directory included by the `members` globs (and not excluded by the `exclude` globs) must | ||
| contain a `pyproject.toml` file; in other words, every member must be a valid Python package. |
Member
There was a problem hiding this comment.
If they do not, what happens? Do we ignore them? Do we fail?
zanieb
reviewed
Aug 19, 2024
docs/concepts/workspaces.md
Outdated
| ## Workspace sources | ||
|
|
||
| There a two main workspace structures: A **root package with helpers** and a **flat workspace**. | ||
| Within a workspace, dependencies on workspace members are facilitated via `tool.uv.sources`, as in: |
Member
There was a problem hiding this comment.
We should link to the dependency sources concept document.
f583e8b to
4ebfb3a
Compare
4ebfb3a to
e686a67
Compare
tmeijn
pushed a commit
to tmeijn/dotfiles
that referenced
this pull request
Aug 21, 2024
This MR contains the following updates: | Package | Update | Change | |---|---|---| | [astral-sh/uv](https://github.com/astral-sh/uv) | minor | `0.2.37` -> `0.3.0` | MR created with the help of [el-capitano/tools/renovate-bot](https://gitlab.com/el-capitano/tools/renovate-bot). **Proposed changes to behavior should be submitted there as MRs.** --- ### Release Notes <details> <summary>astral-sh/uv (astral-sh/uv)</summary> ### [`v0.3.0`](https://github.com/astral-sh/uv/blob/HEAD/CHANGELOG.md#030) [Compare Source](astral-sh/uv@0.2.37...0.3.0) This release introduces the uv [project](https://docs.astral.sh/uv/guides/projects/), [tool](https://docs.astral.sh/uv/guides/tools/), [script](https://docs.astral.sh/uv/guides/scripts/), and [python](https://docs.astral.sh/uv/guides/install-python/) interfaces. If you've been following uv's development, you've probably seen these new commands behind a preview flag. Now, the interfaces are stable and ready for production-use. These features are all documented in [new, comprehensive documentation](https://docs.astral.sh/uv/). This release also stabilizes preview functionality in `uv venv`: - `uv venv --python <version>` will [automatically download](https://docs.astral.sh/uv/concepts/python-versions/#requesting-a-version) the Python version if required - `uv venv` will read the required Python version from the `.python-version` file or `pyproject.toml` The `uv pip` interface should not be affected by any breaking changes. Note the following changelog entries does not include all the new features since they were added incrementally as preview features. See the [feature page](https://docs.astral.sh/uv/getting-started/features/) in the documentation for a comprehensive listing, or read the [blog post](https://astral.sh/blog/uv-unified-python-packaging) for more context on the new features. ##### Breaking changes - Migrate to XDG and Linux strategy for macOS directories ([#​5806](astral-sh/uv#5806)) - Move concurrency settings to top-level ([#​4257](astral-sh/uv#4257)) - Apply system Python filtering to executable name requests ([#​4309](astral-sh/uv#4309)) - Remove `--legacy-setup-py` command-line argument ([#​4255](astral-sh/uv#4255)) - Stabilize preview features ([#​6166](astral-sh/uv#6166)) ##### Enhancements - Add 32-bit Windows target ([#​6252](astral-sh/uv#6252)) - Add support for `python_version in ...` markers ([#​6172](astral-sh/uv#6172)) - Allow user to constrain supported lock environments ([#​6210](astral-sh/uv#6210)) - Lift requirement that .egg-info filenames must include version ([#​6179](astral-sh/uv#6179)) - Change "any of" to "all of" in error messages ([#​6222](astral-sh/uv#6222)) - Collapse redundant dependency clauses enumerating available versions ([#​6160](astral-sh/uv#6160)) - Collapse unavailable packages in resolver errors ([#​6154](astral-sh/uv#6154)) - Fix messages for unavailable packages when range is plural ([#​6221](astral-sh/uv#6221)) - Improve resolver error messages when `--offline` is used ([#​6156](astral-sh/uv#6156)) - Avoid overwriting dependencies with different markers in `uv add` ([#​6010](astral-sh/uv#6010)) - Simplify available package version ranges when the name includes markers or extras ([#​6162](astral-sh/uv#6162)) - Simplify version ranges reported for unavailable packages ([#​6155](astral-sh/uv#6155)) - Rename `environment-markers` to `resolution-markers` ([#​6240](astral-sh/uv#6240)) - Support `uv add -r requirements.txt` ([#​6005](astral-sh/uv#6005)) ##### CLI - Hide global options in `uv generate-shell-completion` ([#​6170](astral-sh/uv#6170)) - Show generate-shell-completion command in `uv help` ([#​6180](astral-sh/uv#6180)) - Special-case reinstalls in environment update summaries ([#​6243](astral-sh/uv#6243)) - Add output when `uv add` and `uv remove` update scripts ([#​6231](astral-sh/uv#6231)) - Add support for `package@latest` in `tool run` ([#​6138](astral-sh/uv#6138)) - Show `python find` output with `-q` ([#​6256](astral-sh/uv#6256)) - Warn when `--upgrade` is passed to `tool run` ([#​6140](astral-sh/uv#6140)) ##### Configuration - Allow customizing the tool install directory with `UV_TOOL_BIN_DIR` ([#​6207](astral-sh/uv#6207)) ##### Performance - Use `FxHash` in `uv-auth` ([#​6149](astral-sh/uv#6149)) ##### Bug fixes - Avoid panicking when the resolver thread encounters a closed channel ([#​6182](astral-sh/uv#6182)) - Respect release-only semantics of `python_full_version` when constructing markers ([#​6171](astral-sh/uv#6171)) - Tolerate missing `[project]` table in `uv venv` ([#​6178](astral-sh/uv#6178)) - Avoid using workspace `lock_path` as relative root ([#​6157](astral-sh/uv#6157)) ##### Documentation - Preview changes are now included in the standard changelog ([#​6259](astral-sh/uv#6259)) - Document dynamic metadata behavior for cache ([#​5993](astral-sh/uv#5993)) - Document the effect of ordering on package priority ([#​6211](astral-sh/uv#6211)) - Make some edits to the workspace concept documentation ([#​6223](astral-sh/uv#6223)) - Update environment variables doc ([#​5994](astral-sh/uv#5994)) - Disable collapsible navigation in the documentation ([#​5674](astral-sh/uv#5674)) - Document `uv add` and `uv remove` behavior with markers ([#​6163](astral-sh/uv#6163)) - Document the Python installation directory ([#​6227](astral-sh/uv#6227)) - Document the `uv.pip` section semantics ([#​6225](astral-sh/uv#6225)) - Document the cache directory ([#​6229](astral-sh/uv#6229)) - Document the tools directory ([#​6228](astral-sh/uv#6228)) - Document yanked packages caveat during sync ([#​6219](astral-sh/uv#6219)) - Link to persistent configuration options in Python versions document ([#​6226](astral-sh/uv#6226)) - Link to the projects concept from the dependencies concept ([#​6224](astral-sh/uv#6224)) - Improvements to the Docker installation guide ([#​6216](astral-sh/uv#6216)) - Increase the size of navigation entries ([#​6233](astral-sh/uv#6233)) - Install `ca-certificates` in docker and use pipefail ([#​6208](astral-sh/uv#6208)) - Add script support to feature highlights in index ([#​6251](astral-sh/uv#6251)) - Show `uv generate-shell-completion` in CLI documentation reference ([#​6146](astral-sh/uv#6146)) - Update Docker guide for projects ([#​6217](astral-sh/uv#6217)) - Use `uv add --script` in guide ([#​6215](astral-sh/uv#6215)) - Show pinned version example on in GitHub Actions integration guide ([#​6234](astral-sh/uv#6234)) </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever MR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this MR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this MR, check this box --- This MR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy40NDAuNyIsInVwZGF0ZWRJblZlciI6IjM3LjQ0MC43IiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJSZW5vdmF0ZSBCb3QiXX0=-->
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.