简体   繁体   中英

VSCode "Writing login information to the keychain failed with error 'UNIX[No such file or directory]'."

After solving this and posting to AskDifferent.... I realized this is probably the case with any OS:

in my case I was using MacOS High Sierra 10.13.6 with new install of VSCode 1.50.0 (see screenshots below):

Scenario:

  • Attempt to "Sign-in to Sync Settings"

    在此处输入图片说明

  • web/browser-based SSO redirects to Microsoft and/or Github browser login

  • login fails - error message in VSCode:

Error:

Writing login information to the keychain failed with error 'UNIX[No such file or directory]'.

System Details:

  • New install of VSCode For Mac:
    在此处输入图片说明

  • And MacOS info:
    ![在此处输入图片说明

This is a keychain error which look similar to some others upon Google search, but I didn't find this exact error... so, adding the solution here...

SOLUTION

  1. Attempt to "Sync Settings" by logging into Microsoft or Github
  2. this will fail as OP states... but
  3. close ALL instances/windows of VSCode
  4. RESTART VSCode
  5. You should be prompted for Apple KeyChain permissions like this image shows: 在此处输入图片说明
  6. Type in your MacOS root password
  7. You will either immediately login without error(s) ... or....
  8. RESTART VSCode AGAIN
  9. "Sync Settings" / login once more

On my system all I had to do is :

$ sudo apt install gnome-keyring

So I think on MacOs you can also easily solve this issue by installing a keyring system. I don't know MacOs though so I couldn't provide a name.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM