~sircmpwn/dispatch.sr.ht#20: Deal with users who have revoked their GitHub OAuth token

Status
REPORTED
Submitter
~sircmpwn
Assigned to
No-one
Submitted
7 months ago
Updated
7 months ago
Labels
No labels applied.

~sircmpwn 7 months ago

Traceback (most recent call last):
  File "/usr/lib/python3.7/site-packages/flask/app.py", line 2292, in wsgi_app
    response = self.full_dispatch_request()
  File "/usr/lib/python3.7/site-packages/flask/app.py", line 1815, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/usr/lib/python3.7/site-packages/flask/app.py", line 1718, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/usr/lib/python3.7/site-packages/flask/_compat.py", line 35, in reraise
    raise value
  File "/usr/lib/python3.7/site-packages/flask/app.py", line 1813, in full_dispatch_request
    rv = self.dispatch_request()
  File "/usr/lib/python3.7/site-packages/flask/app.py", line 1799, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "/usr/lib/python3.7/site-packages/dispatchsrht/tasks/github/github_commit_to_build.py", line 84, in
_webhook
    return submit_build(hook, repo, commit, secrets=hook.secrets)
  File "/usr/lib/python3.7/site-packages/dispatchsrht/tasks/github/auth.py", line 117, in submit_build
    repo = github.get_repo(repo["full_name"])
  File "/usr/lib/python3.7/site-packages/github/MainClass.py", line 294, in get_repo
    "%s%s" % (url_base, full_name_or_id)
  File "/usr/lib/python3.7/site-packages/github/Requester.py", line 264, in requestJsonAndCheck
    return self.__check(*self.requestJson(verb, url, parameters, headers, input,
self.__customConnection(url)))
  File "/usr/lib/python3.7/site-packages/github/Requester.py", line 275, in __check
    raise self.__createException(status, responseHeaders, output)
github.GithubException.BadCredentialsException: 401 {'message': 'Bad credentials', 'documentation_url':
'https://developer.github.com/v3'}