Skip to content

Commit

Permalink
Properly format test publish error (#11001)
Browse files Browse the repository at this point in the history
  • Loading branch information
konstin authored Jan 27, 2025
1 parent a00f6f5 commit bd9607b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions scripts/publish/test_publish.py
Original file line number Diff line number Diff line change
Expand Up @@ -380,15 +380,16 @@ def publish_project(target: str, uv: Path, client: httpx.Client):
)

args = [uv, "publish", "--publish-url", publish_url, *extra_args]
result = run(args, cwd=project_dir, env=env, stderr=PIPE)
result = run(args, cwd=project_dir, env=env, text=True, stderr=PIPE)
if result.returncode == 0:
# Successful upload
break

retries -= 1
if retries > 0:
print(
f"Publish failed, retrying after 10s: {result.stderr}", file=sys.stderr
f"Publish failed, retrying after 10s:\n---\n{result.stderr}\n---",
file=sys.stderr,
)
sleep(10)
else:
Expand Down

0 comments on commit bd9607b

Please sign in to comment.