Skip to content

Commit f63b430

Browse files
authored
pin setuptools in the modify script (#6669)
1 parent c37ce91 commit f63b430

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

.github/workflows/configure-testpypi-version.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,13 @@ def update(mapping, path, value, sep="/"):
3838

3939
content = args.path.read_text()
4040
decoded = tomli.loads(content)
41-
updated = update(
41+
with_local_scheme = update(
4242
decoded, "tool.setuptools_scm.local_scheme", "no-local-version", sep="."
4343
)
44+
# work around a bug in setuptools / setuptools-scm
45+
with_setuptools_pin = copy.deepcopy(with_local_scheme)
46+
requires = extract(with_setuptools_pin, "build-system.requires", sep=".")
47+
requires[0] = "setuptools>=42,<60"
4448

45-
new_content = tomli_w.dumps(updated)
46-
49+
new_content = tomli_w.dumps(with_setuptools_pin)
4750
args.path.write_text(new_content)

0 commit comments

Comments
 (0)