From d4bc0fc38771571d4e81db3029a19c6dea0de7b7 Mon Sep 17 00:00:00 2001 From: Gary Hammock Date: Sat, 8 Jul 2023 18:28:57 -0500 Subject: [PATCH 1/3] Added PyPI source pyproject.toml example to repositories.md. --- docs/repositories.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/docs/repositories.md b/docs/repositories.md index 0446d3ec1cc..aa81d458d63 100644 --- a/docs/repositories.md +++ b/docs/repositories.md @@ -174,6 +174,18 @@ poetry source add --priority=primary PyPI This way, the priority of PyPI can be set in a fine-granular way. +The equivalent specification in `pyproject.toml` is: + +```toml +[[tool.poetry.source]] +name = "pypi" +priority = "supplemental" +``` + +**Omit the `url` when specifying PyPI as a supplemental source.** Because PyPI is internally configured +with Poetry, the PyPI repository cannot be configured with a given URL. Remember, you can always use +`poetry check` to ensure the validity of the `pyproject.toml` file. + {{% /warning %}} {{% warning %}} From 1266e1d04558a77750780f6115c0e215034ce5fc Mon Sep 17 00:00:00 2001 From: Gary Hammock Date: Wed, 26 Jul 2023 16:18:50 -0500 Subject: [PATCH 2/3] fixed `priority` key per https://github.com/python-poetry/poetry/pull/8171#discussion_r1272407252 --- docs/repositories.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/repositories.md b/docs/repositories.md index aa81d458d63..3262a2cd7f3 100644 --- a/docs/repositories.md +++ b/docs/repositories.md @@ -179,7 +179,7 @@ The equivalent specification in `pyproject.toml` is: ```toml [[tool.poetry.source]] name = "pypi" -priority = "supplemental" +priority = "primary" ``` **Omit the `url` when specifying PyPI as a supplemental source.** Because PyPI is internally configured From 4c7574f1dee6c6161c29a8840c915562278f83b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Randy=20D=C3=B6ring?= <30527984+radoering@users.noreply.github.com> Date: Thu, 27 Jul 2023 18:25:35 +0200 Subject: [PATCH 3/3] Update docs/repositories.md --- docs/repositories.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/repositories.md b/docs/repositories.md index 3262a2cd7f3..ba71b8369b4 100644 --- a/docs/repositories.md +++ b/docs/repositories.md @@ -182,8 +182,8 @@ name = "pypi" priority = "primary" ``` -**Omit the `url` when specifying PyPI as a supplemental source.** Because PyPI is internally configured -with Poetry, the PyPI repository cannot be configured with a given URL. Remember, you can always use +**Omit the `url` when specifying PyPI explicitly.** Because PyPI is internally configured +with Poetry, the PyPI repository cannot be configured with a given URL. Remember, you can always use `poetry check` to ensure the validity of the `pyproject.toml` file. {{% /warning %}}