python-update-checker 1.2.0__py3-none-any.whl → 1.4.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- puc/__init__.py +1 -1
- puc/pyprojecttoml.py +29 -0
- puc/uvlock.py +11 -16
- {python_update_checker-1.2.0.dist-info → python_update_checker-1.4.0.dist-info}/METADATA +16 -1
- python_update_checker-1.4.0.dist-info/RECORD +11 -0
- {python_update_checker-1.2.0.dist-info → python_update_checker-1.4.0.dist-info}/WHEEL +1 -1
- python_update_checker-1.2.0.dist-info/RECORD +0 -11
- {python_update_checker-1.2.0.dist-info → python_update_checker-1.4.0.dist-info}/entry_points.txt +0 -0
puc/__init__.py
CHANGED
puc/pyprojecttoml.py
CHANGED
|
@@ -47,6 +47,11 @@ def handle_pyproject_toml(
|
|
|
47
47
|
if not project:
|
|
48
48
|
logger.warning(f"no project defined in {pyproject_path}")
|
|
49
49
|
return updatable
|
|
50
|
+
if pyproject.get("tool", {}).get("poetry", {}).get("dependencies", {}):
|
|
51
|
+
logger.warning(f"[tool.poetry.dependencies] detected in {pyproject_path}")
|
|
52
|
+
logger.warning(
|
|
53
|
+
"consider migrating to uv, see https://docs.astral.sh/uv/guides/migration/"
|
|
54
|
+
)
|
|
50
55
|
projectname = project.get("name", None)
|
|
51
56
|
logger.debug(f"found project name {projectname}")
|
|
52
57
|
# project dependencies
|
|
@@ -94,6 +99,30 @@ def handle_pyproject_toml(
|
|
|
94
99
|
constraint_file=constraint_file,
|
|
95
100
|
color=color,
|
|
96
101
|
)
|
|
102
|
+
# update legacy uv dev dependencies
|
|
103
|
+
# See https://docs.astral.sh/uv/concepts/projects/dependencies/#legacy-dev-dependencies
|
|
104
|
+
tool_uv = pyproject.get("tool", {}).get("uv", {})
|
|
105
|
+
deps = tool_uv.get("dev-dependencies", [])
|
|
106
|
+
if deps:
|
|
107
|
+
logger.warning(
|
|
108
|
+
f"Found legacy tool.uv.dev-dependencies in {pyproject_path}, replace with dependency-groups.dev"
|
|
109
|
+
)
|
|
110
|
+
logger.warning(
|
|
111
|
+
"See https://docs.astral.sh/uv/concepts/projects/dependencies/#development-dependencies"
|
|
112
|
+
)
|
|
113
|
+
updatable += update_pyproject_dependencies(
|
|
114
|
+
deps,
|
|
115
|
+
project_dir,
|
|
116
|
+
projectname,
|
|
117
|
+
group="dev",
|
|
118
|
+
command=command,
|
|
119
|
+
packages=packages,
|
|
120
|
+
exclude_newer=exclude_newer,
|
|
121
|
+
exclude_newer_package=exclude_newer_package,
|
|
122
|
+
exclude_packages=exclude_packages,
|
|
123
|
+
constraint_file=constraint_file,
|
|
124
|
+
color=color,
|
|
125
|
+
)
|
|
97
126
|
if command == "update":
|
|
98
127
|
logger.info(f"updated {updatable} package version(s) in {pyproject_path}")
|
|
99
128
|
return updatable
|
puc/uvlock.py
CHANGED
|
@@ -81,22 +81,17 @@ def check_source_registry(uvpackage, name):
|
|
|
81
81
|
"""
|
|
82
82
|
# check package source for skip reasons
|
|
83
83
|
source = uvpackage.get("source", {})
|
|
84
|
-
|
|
85
|
-
#
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
#
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
return False
|
|
96
|
-
if "git" in source:
|
|
97
|
-
# skip git packages provided by URL
|
|
98
|
-
logger.info(f"skip git package {name!r}")
|
|
99
|
-
return False
|
|
84
|
+
skip_sources = (
|
|
85
|
+
"virtual", # virtual packages (ie. the project itself)
|
|
86
|
+
"editable", # editable packages
|
|
87
|
+
"path", # local packages provided by file path
|
|
88
|
+
"git", # git packages provided by URL
|
|
89
|
+
"directory", # directory packages provided by local path
|
|
90
|
+
)
|
|
91
|
+
for skip_source in skip_sources:
|
|
92
|
+
if skip_source in source:
|
|
93
|
+
logger.info(f"skip {skip_source} package {name!r}")
|
|
94
|
+
return False
|
|
100
95
|
if "registry" not in source:
|
|
101
96
|
logger.warning(f"no registry entry found for package {name!r}")
|
|
102
97
|
return True
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: python-update-checker
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.4.0
|
|
4
4
|
License-Expression: GPL-3.0-only
|
|
5
5
|
Classifier: Development Status :: 5 - Production/Stable
|
|
6
6
|
Classifier: Environment :: Console
|
|
@@ -48,6 +48,8 @@ uv sync
|
|
|
48
48
|
* supports pyproject.toml, uv.lock and requirements.txt formats
|
|
49
49
|
* supports `[project.dependencies]`, `[project.optional-dependencies]`
|
|
50
50
|
and `[dependency-groups]` in pyproject.toml
|
|
51
|
+
* supports legacy dependency format `[tool.uv.dev-dependencies]`
|
|
52
|
+
in pyproject.toml
|
|
51
53
|
* supports recursive references (-r) in requirements.txt formats
|
|
52
54
|
* can run in check only mode, ie. it checks if updates are available
|
|
53
55
|
* limit updates to specific packages
|
|
@@ -126,6 +128,19 @@ Dependencies are
|
|
|
126
128
|
|
|
127
129
|
puc needs Python >= 3.11 since it uses the tomllib Python module.
|
|
128
130
|
|
|
131
|
+
## Updating minimum version requirements
|
|
132
|
+
|
|
133
|
+
Dependencies like `requests>=1.12` or `django>5` specify a
|
|
134
|
+
minimum version requirement.
|
|
135
|
+
|
|
136
|
+
Minimum requirements are necessary to work with different versioned
|
|
137
|
+
dependencies, since different distributions package different
|
|
138
|
+
versions of those dependencies.
|
|
139
|
+
Minimum requirements change when the project uses a
|
|
140
|
+
feature that is only available in newer versions of a dependency.
|
|
141
|
+
This cannot be determined automatically by puc.
|
|
142
|
+
So minimum version requirements should be updated manually.
|
|
143
|
+
|
|
129
144
|
## Limitations
|
|
130
145
|
|
|
131
146
|
* No support for custom dependency formats in pyproject.toml
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
puc/__init__.py,sha256=AEBS_Mnzv6WYHiwut4ZHUSRyQII2WZ-miiGiaUeJ3qo,90
|
|
2
|
+
puc/cli.py,sha256=5dE0hpzof4AxssN5BczcLptz5XnoLrhSes3FwVHZ9NQ,8328
|
|
3
|
+
puc/dependencies.py,sha256=4XLPiCnulGVT29bVB6Blkh9irjUGxfChP01YqqofYTw,6717
|
|
4
|
+
puc/logging.py,sha256=VBojYqr7-l-aLeNqrBqTJyHuEINzdBx1CObQg5XiC-k,2222
|
|
5
|
+
puc/pyprojecttoml.py,sha256=TYV6csLLRiRORie6X1EuHKAXh01vh5IjWUiNr2Fgbco,8761
|
|
6
|
+
puc/requirementstxt.py,sha256=CVnyG3Pkmse9TGLPEx1Uls1CFuDJBu2l9biXId58q4E,5617
|
|
7
|
+
puc/uvlock.py,sha256=yGkFrBAzlvzF01YVRJrztQoupAOdobRJ8Y5Al2Da7mw,5258
|
|
8
|
+
python_update_checker-1.4.0.dist-info/WHEEL,sha256=mru_b36sH6joUMnwf7IlFCun3RoDjrNg9RcfBmEcqsE,81
|
|
9
|
+
python_update_checker-1.4.0.dist-info/entry_points.txt,sha256=mQuGfBukyjyo7ssOHSIycAlRdQkrA1ewAth6tsV_T60,38
|
|
10
|
+
python_update_checker-1.4.0.dist-info/METADATA,sha256=TnHHxx8Q50VIqVFLP5xakLqd-KmawS_-9FlLlFD7eNo,5960
|
|
11
|
+
python_update_checker-1.4.0.dist-info/RECORD,,
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
puc/__init__.py,sha256=Pt55DqeJLcfKUlPCHcNViJ5xp3i2U9X3lB-cuggs2z0,90
|
|
2
|
-
puc/cli.py,sha256=5dE0hpzof4AxssN5BczcLptz5XnoLrhSes3FwVHZ9NQ,8328
|
|
3
|
-
puc/dependencies.py,sha256=4XLPiCnulGVT29bVB6Blkh9irjUGxfChP01YqqofYTw,6717
|
|
4
|
-
puc/logging.py,sha256=VBojYqr7-l-aLeNqrBqTJyHuEINzdBx1CObQg5XiC-k,2222
|
|
5
|
-
puc/pyprojecttoml.py,sha256=dPIGCsc4gyGv1u4cS6KI5l1y0m__D5bEFGJVGYGHR9c,7410
|
|
6
|
-
puc/requirementstxt.py,sha256=CVnyG3Pkmse9TGLPEx1Uls1CFuDJBu2l9biXId58q4E,5617
|
|
7
|
-
puc/uvlock.py,sha256=ufV9ByobAC9PuEKanY7NAwVDXF0r5N2RBdi4oegUu9k,5383
|
|
8
|
-
python_update_checker-1.2.0.dist-info/WHEEL,sha256=Kot-FOXwz2no6rGIg4et79Z7m6vcKPAXr2Y6fTFpZuI,81
|
|
9
|
-
python_update_checker-1.2.0.dist-info/entry_points.txt,sha256=mQuGfBukyjyo7ssOHSIycAlRdQkrA1ewAth6tsV_T60,38
|
|
10
|
-
python_update_checker-1.2.0.dist-info/METADATA,sha256=QasUB3Xfjj7MXpTE4l-_pK_OweLqYNXC2MrkkoLM9p4,5355
|
|
11
|
-
python_update_checker-1.2.0.dist-info/RECORD,,
|
{python_update_checker-1.2.0.dist-info → python_update_checker-1.4.0.dist-info}/entry_points.txt
RENAMED
|
File without changes
|