Skip to content

Commit 4599a54

Browse files
committed
Mask API key in release summary
1 parent 709c826 commit 4599a54

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

run_release.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,7 +252,9 @@ def __init__(
252252
print(f"- Normalized release tag: {release_tag.normalized()}")
253253
print(f"- Git repo: {self.db['git_repo']}")
254254
print(f"- SSH username: {self.db['ssh_user']}")
255-
print(f"- python.org API key: {self.db['auth_info']}")
255+
user, key = self.db["auth_info"].split(":")
256+
masked = "*" * (len(key) - 4) + key[-4:]
257+
print(f"- python.org API key: {user}:{masked}")
256258
print(f"- Sign with GPG: {self.db['sign_gpg']}")
257259
print()
258260

0 commit comments

Comments
 (0)