Skip to content

Commit

Permalink
Fixing a max length error on deploy/publish script with GitHub API, a…
Browse files Browse the repository at this point in the history
…nd adding better errors for GitHub specific issues.
  • Loading branch information
jonoomph committed Aug 25, 2021
1 parent 377a8f4 commit 6e636e8
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion installer/deploy.py
Expand Up @@ -33,6 +33,7 @@
import re
import urllib3
from github3 import login
from github3.models import GitHubError
from requests.auth import HTTPBasicAuth
from requests import post, get, head
from build_server import (
Expand Down Expand Up @@ -185,7 +186,7 @@ def main():
github_release_name,
target_commitish=git_branch_name,
prerelease=True,
body=formatted_logs.get(repo_name))
body=formatted_logs.get(repo_name)[:125000])

# Upload all deploy artifacts/installers to GitHub
# NOTE: ONLY for `openshot-qt` repo
Expand Down Expand Up @@ -367,6 +368,8 @@ def main():
except Exception as ex:
tb = traceback.format_exc()
error("Unhandled %s exception: %s - %s" % (script_mode, str(ex), str(tb)))
if type(ex) == GitHubError:
error(str(ex.errors))

if not errors_detected:
output("Successfully completed %s script!" % script_mode)
Expand Down

0 comments on commit 6e636e8

Please sign in to comment.