RESOLVED FIXED 242647
Using git-webkit pr via SSH dumps errors
https://bugs.webkit.org/show_bug.cgi?id=242647
Summary Using git-webkit pr via SSH dumps errors
Yusuke Suzuki
Reported 2022-07-12 13:45:52 PDT
Using git-webkit pr via SSH does not work. ``` No valid authentication session for Radar 'main' is not a pull request branch, enter issue URL or title of new issue: https://bugs.webkit.org/show_bug.cgi?id=242599 Traceback (most recent call last): File "/Users/yusukesuzuki/dev/OpenSource/Tools/Scripts/libraries/autoinstalled/python-3-arm64/keyring/backends/macOS/__init__.py", line 49, in get_password return api.find_generic_password(self.keychain, service, username) File "/Users/yusukesuzuki/dev/OpenSource/Tools/Scripts/libraries/autoinstalled/python-3-arm64/keyring/backends/macOS/api.py", line 144, in find_generic_password Error.raise_for_status(status) File "/Users/yusukesuzuki/dev/OpenSource/Tools/Scripts/libraries/autoinstalled/python-3-arm64/keyring/backends/macOS/api.py", line 114, in raise_for_status raise cls(status, "Unknown Error") keyring.backends.macOS.api.Error: (-25308, 'Unknown Error') During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/Users/yusukesuzuki/dev/Internal/Tools/Scripts//git-webkit", line 89, in <module> sys.exit(program.main( File "/Users/yusukesuzuki/dev/OpenSource/Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/__init__.py", line 148, in main return parsed.main( File "/Users/yusukesuzuki/dev/OpenSource/Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/pull_request.py", line 456, in main branch_point = cls.pull_request_branch_point(repository, args, **kwargs) File "/Users/yusukesuzuki/dev/OpenSource/Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/pull_request.py", line 179, in pull_request_branch_point if Branch.main( File "/Users/yusukesuzuki/dev/OpenSource/Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/branch.py", line 114, in main if issue and issue.title and not redact and not issue.redacted: File "/Users/yusukesuzuki/dev/OpenSource/Tools/Scripts/libraries/webkitbugspy/webkitbugspy/issue.py", line 89, in title self.tracker.populate(self, 'title') File "/Users/yusukesuzuki/dev/OpenSource/Tools/Scripts/libraries/webkitbugspy/webkitbugspy/bugzilla.py", line 160, in populate response = requests.get('{}/rest/bug/{}{}'.format(self.url, issue.id, self._login_arguments(required=False))) File "/Users/yusukesuzuki/dev/OpenSource/Tools/Scripts/libraries/webkitbugspy/webkitbugspy/bugzilla.py", line 138, in _login_arguments username, password = self.credentials(required=required) File "/Users/yusukesuzuki/dev/OpenSource/Tools/Scripts/libraries/webkitbugspy/webkitbugspy/bugzilla.py", line 124, in credentials return webkitcorepy.credentials( File "/Users/yusukesuzuki/dev/OpenSource/Tools/Scripts/libraries/webkitcorepy/webkitcorepy/credentials.py", line 71, in credentials username = keyring.get_password(url, 'username') File "/Users/yusukesuzuki/dev/OpenSource/Tools/Scripts/libraries/autoinstalled/python-3-arm64/keyring/core.py", line 55, in get_password return get_keyring().get_password(service_name, username) File "/Users/yusukesuzuki/dev/OpenSource/Tools/Scripts/libraries/autoinstalled/python-3-arm64/keyring/backends/macOS/__init__.py", line 55, in get_password raise KeyringError("Can't get password from keychain: " "{}".format(e)) keyring.errors.KeyringError: Can't get password from keychain: (-25308, 'Unknown Error') ```
Attachments
Alexey Proskuryakov
Comment 1 2022-07-13 13:51:07 PDT
I suspect that this may be unfixable as long as we use Keychain for credentials.
Alexey Proskuryakov
Comment 2 2022-07-14 14:50:24 PDT
Elliott pointed out in bug 242726 that keychain does work over ssh. So we just need to run `security unlock`, which will ask for user's password.
Yusuke Suzuki
Comment 3 2022-07-17 17:53:47 PDT
(In reply to Alexey Proskuryakov from comment #2) > Elliott pointed out in bug 242726 that keychain does work over ssh. So we > just need to run `security unlock`, which will ask for user's password. Nice!!! Thank you
Radar WebKit Bug Importer
Comment 4 2022-07-19 13:46:15 PDT
Yusuke Suzuki
Comment 5 2022-07-19 14:11:31 PDT
I think git-webkit should detect this condition, and instead of crashing, suggest `security unlock` and/or do `security unlock` to proceed.
Jonathan Bedard
Comment 6 2022-07-21 10:24:05 PDT
This does seem quite detectable, we only have a single function which access the keychain this way.
Ryan Haddad
Comment 7 2023-01-18 11:17:56 PST
*** Bug 242726 has been marked as a duplicate of this bug. ***
Alexey Proskuryakov
Comment 8 2025-05-17 14:58:58 PDT
Brianna Fan
Comment 9 2025-06-24 15:29:12 PDT
EWS
Comment 10 2025-06-25 10:45:29 PDT
Committed 296626@main (2cfc0247c976): <https://commits.webkit.org/296626@main> Reviewed commits have been landed. Closing PR #47141 and removing active labels.
Note You need to log in before you can comment on or make changes to this bug.