-
Notifications
You must be signed in to change notification settings - Fork 1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Handle explicit PyPI source in pyproject.toml
When a github user has poetry >= 1.5.0, they will be nagged by a warning to run `poetry source add pypi`, which will add the following section to the users pyproject.toml: ```toml [[tool.poetry.source]] name = "PyPI" priority = "primary" ``` This causes the problem that the index_finder will fail due to this section missing a url. This commit works around this issue by skip that case, since we will default to the pypi official url anyways in that case. Co-authored-by: Galen Rice <galen.rice@torqata.com>
- Loading branch information
1 parent
44e080f
commit 15078eb
Showing
4 changed files
with
49 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
[tool.poetry] | ||
name = "PythonProjects" | ||
version = "2.0.0" | ||
homepage = "https://github.com/roghu/py3_projects" | ||
license = "MIT" | ||
readme = "README.md" | ||
authors = ["Dependabot <support@dependabot.com>"] | ||
description = "Various small python projects." | ||
|
||
[tool.poetry.dependencies] | ||
python = "^3.7" | ||
requests = "2.18.0" | ||
|
||
[[tool.poetry.source]] | ||
name = "PyPI" | ||
priority = "primary" |
16 changes: 16 additions & 0 deletions
16
python/spec/fixtures/pyproject_files/pypi_explicit_lowercase.toml
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
[tool.poetry] | ||
name = "PythonProjects" | ||
version = "2.0.0" | ||
homepage = "https://github.com/roghu/py3_projects" | ||
license = "MIT" | ||
readme = "README.md" | ||
authors = ["Dependabot <support@dependabot.com>"] | ||
description = "Various small python projects." | ||
|
||
[tool.poetry.dependencies] | ||
python = "^3.7" | ||
requests = "2.18.0" | ||
|
||
[[tool.poetry.source]] | ||
name = "pypi" | ||
priority = "primary" |