Bug 241272

Summary: `git-webkit setup` should offer to regenerate expired GitHub personal access tokens
Product: WebKit Reporter: Wenson Hsieh <wenson_hsieh>
Component: Tools / TestsAssignee: Nobody <webkit-unassigned>
Status: RESOLVED DUPLICATE    
Severity: Normal CC: ap, jbedard, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 239082    

Wenson Hsieh
Reported 2022-06-03 09:41:59 PDT
Currently, attempting `git-webkit setup` with an access token that has expired causes the setup script to offer to create a WebKit fork; picking either option (Yes or No) causes the script to fail. ``` % gw setup WARNING:webkitscmpy:Setting merging behavior for changelogs... WARNING:webkitscmpy:Set merging behavior for changelogs! Create a private fork of 'WebKit' belonging to 'whsieh' ([Yes]/No): Yes Failed to create a fork of 'WebKit' belonging to 'whsieh' URL: https://api.github.com/repos/WebKit/WebKit/forks Server replied with status code 401: {"message":"Bad credentials","documentation_url":"https://docs.github.com/rest"} Setup failed % gw setup WARNING:webkitscmpy:Setting merging behavior for changelogs... WARNING:webkitscmpy:Set merging behavior for changelogs! Create a private fork of 'WebKit' belonging to 'whsieh' ([Yes]/No): No Setup failed ``` The workaround was to regenerate my expired token via https://github.com/settings/tokens and update the token stored in my keychain; it would be nice if the script detected this scenario and surfaced a better error message.
Attachments
Radar WebKit Bug Importer
Comment 1 2022-06-10 09:42:12 PDT
Jonathan Bedard
Comment 2 2023-01-05 16:08:51 PST
*** This bug has been marked as a duplicate of bug 240883 ***
Jonathan Bedard
Comment 3 2023-01-05 16:09:27 PST
We ended up fixing this in 240883 by checking the expiration of a user's token.
Note You need to log in before you can comment on or make changes to this bug.