Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Random failure with github.GithubException.GithubException: 500 null #110

Closed
TheSlowGrowth opened this issue Apr 10, 2021 · 4 comments · Fixed by #111
Closed

Random failure with github.GithubException.GithubException: 500 null #110

TheSlowGrowth opened this issue Apr 10, 2021 · 4 comments · Fixed by #111
Labels
enhancement New feature or request

Comments

@TheSlowGrowth
Copy link

TheSlowGrowth commented Apr 10, 2021

I recently observed this random failure. It seems completely unrelated to the actual commit that the workflow was triggered for, as the workflow had previously executed without an error for the same commit.

Not sure where the actual error is, but here's the stacktrace:

Run EnricoMi/publish-unit-test-result-action@v1
  with:
    files: firmware/tests/build/bin/**/*.xml
    github_token: ***
    check_name: Unit Test Results
    fail_on: test failures
    hide_comments: all but latest
    comment_on_pr: true
    pull_request_build: merge
    check_run_annotations: all tests, skipped tests
/usr/bin/docker run --name ghcrioenricomipublishunittestresultactionv111_09e53a --label 5588e4 --workdir /github/workspace --rm -e INPUT_FILES -e INPUT_GITHUB_TOKEN -e INPUT_COMMIT -e INPUT_CHECK_NAME -e INPUT_COMMENT_TITLE -e INPUT_FAIL_ON -e INPUT_REPORT_INDIVIDUAL_RUNS -e INPUT_DEDUPLICATE_CLASSES_BY_FILE_NAME -e INPUT_HIDE_COMMENTS -e INPUT_COMMENT_ON_PR -e INPUT_PULL_REQUEST_BUILD -e INPUT_TEST_CHANGES_LIMIT -e INPUT_CHECK_RUN_ANNOTATIONS -e INPUT_CHECK_RUN_ANNOTATIONS_BRANCH -e HOME -e GITHUB_JOB -e GITHUB_REF -e GITHUB_SHA -e GITHUB_REPOSITORY -e GITHUB_REPOSITORY_OWNER -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_RETENTION_DAYS -e GITHUB_ACTOR -e GITHUB_WORKFLOW -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GITHUB_EVENT_NAME -e GITHUB_SERVER_URL -e GITHUB_API_URL -e GITHUB_GRAPHQL_URL -e GITHUB_WORKSPACE -e GITHUB_ACTION -e GITHUB_EVENT_PATH -e GITHUB_ACTION_REPOSITORY -e GITHUB_ACTION_REF -e GITHUB_PATH -e GITHUB_ENV -e RUNNER_OS -e RUNNER_TOOL_CACHE -e RUNNER_TEMP -e RUNNER_WORKSPACE -e ACTIONS_RUNTIME_URL -e ACTIONS_RUNTIME_TOKEN -e ACTIONS_CACHE_URL -e GITHUB_ACTIONS=true -e CI=true -v "/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/_temp/_runner_file_commands":"/github/file_commands" -v "/home/runner/work/Wunderkiste/Wunderkiste":"/github/workspace" ghcr.io/enricomi/publish-unit-test-result-action:v1.11
2021-04-10 07:50:41 +0000 - publish-unit-test-results -  INFO - reading firmware/tests/build/bin/**/*.xml
2021-04-10 07:50:41 +0000 - publish.publisher -  INFO - publishing success results for commit 6cee9c9b0d9b3fd0f7758337e79225cf24db0f21
2021-04-10 07:50:41 +0000 - publish.publisher -  INFO - creating check
2021-04-10 07:50:43 +0000 - publish.publisher -  INFO - creating comment
Traceback (most recent call last):
  File "/action/publish_unit_test_results.py", line 194, in <module>
    main(settings)
  File "/action/publish_unit_test_results.py", line 68, in main
    Publisher(settings, gh, gha).publish(stats, results.case_results, conclusion)
  File "/action/publish/publisher.py", line 55, in publish
    self.publish_comment(self._settings.comment_title, stats, pull, check_run, cases)
  File "/action/publish/publisher.py", line 244, in publish_comment
    pull_request.create_issue_comment(f'## {title}\n{summary}')
  File "/usr/local/lib/python3.6/site-packages/github/PullRequest.py", line 457, in create_issue_comment
    "POST", self.issue_url + "/comments", input=post_parameters
  File "/usr/local/lib/python3.6/site-packages/github/Requester.py", line 317, in requestJsonAndCheck
    verb, url, parameters, headers, input, self.__customConnection(url)
  File "/usr/local/lib/python3.6/site-packages/github/Requester.py", line 340, in __check
    raise self.__createException(status, responseHeaders, output)
github.GithubException.GithubException: 500 null

Here's a link to the specific workflow run

Any ideas what the cause may be?

@EnricoMi
Copy link
Owner

This looks like a 500 HTTP response from GitHub, an Internal Server Error. I would have thought the GitHub client retries that call into the GitHub API. It is very annoying when your workflow fails on such a transient error.

Let me investigate the retry a bit.

@EnricoMi
Copy link
Owner

I have replicated the issue and changed the retry setup. This should be fixed now. Thanks for reporting!

@TheSlowGrowth
Copy link
Author

Thanks for fixing this so quickly!

@EnricoMi
Copy link
Owner

This has been released and is now available via @v1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants