Skip to content

Commit 08c294c

Browse files
committed
Validate that there is a GITHUB_ACCESS_TOKEN set
We need the github API in order to fetch the release name from a SHA.
1 parent 8bdfd59 commit 08c294c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

bin/show_puppet_versions.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,9 @@ def enhance_with_release_number(server_mapping):
5252
Because many of the SHAs will be the same, there is caching in place to
5353
avoid unnecessary calls.
5454
"""
55-
access_token = os.environ['GITHUB_ACCESS_TOKEN']
55+
access_token = os.environ.get('GITHUB_ACCESS_TOKEN')
56+
if access_token is None:
57+
raise ValueError("Please set GITHUB_ACCESS_TOKEN in order to continue")
5658

5759
for server_name, puppet_information in server_mapping.iteritems():
5860
sha = puppet_information.get('sha')

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy