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

Can't authenticate #1251

Closed
cappslock opened this issue Jun 27, 2019 · 9 comments
Closed

Can't authenticate #1251

cappslock opened this issue Jun 27, 2019 · 9 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug

Comments

@cappslock
Copy link

Issue Type: Bug

When attempting to sign in, nothing happens besides an error message: "Error signing in to github.com".

This is logged to the output:

[Info] Looking for git repository
[Info] Git repository found, initializing review manager and pr tree view.
[Info] Found GitHub remote
[Info] Error signing in to github.com: TypeError: Cannot set property 'text' of undefined
[Info] TypeError: Cannot set property 'text' of undefined
	at t.CredentialStore.willStartLogin (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:358635)
	at t.CredentialStore.<anonymous> (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:356720)
	at Generator.next (<anonymous>)
	at n (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:354529)
	at new Promise (<anonymous>)
	at n (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:354306)
	at t.CredentialStore.login (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:356515)
	at t.CredentialStore.<anonymous> (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:356396)
	at Generator.next (<anonymous>)
	at o (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:354362)
[Info] Error signing in to github.com: TypeError: Cannot set property 'text' of undefined
[Info] TypeError: Cannot set property 'text' of undefined
	at t.CredentialStore.willStartLogin (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:358635)
	at t.CredentialStore.<anonymous> (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:356720)
	at Generator.next (<anonymous>)
	at o (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:354362)
[Info] Error signing in to github.com: TypeError: Cannot set property 'text' of undefined
[Info] TypeError: Cannot set property 'text' of undefined
	at t.CredentialStore.willStartLogin (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:358635)
	at t.CredentialStore.<anonymous> (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:356720)
	at Generator.next (<anonymous>)
	at o (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:354362)
[Info] Error signing in to github.com: TypeError: Cannot set property 'text' of undefined
[Info] TypeError: Cannot set property 'text' of undefined
	at t.CredentialStore.willStartLogin (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:358635)
	at t.CredentialStore.<anonymous> (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:356720)
	at Generator.next (<anonymous>)
	at o (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:354362)

Extension version: 0.8.0
VS Code version: Code 1.35.1 (c7d83e57cd18f18026a8162d042843bda1bcf21f, 2019-06-12T14:29:22.216Z)
OS version: Darwin x64 18.6.0

System Info
Item Value
CPUs Intel(R) Core(TM) i7-6700HQ CPU @ 2.60GHz (8 x 2600)
GPU Status 2d_canvas: enabled
checker_imaging: disabled_off
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
native_gpu_memory_buffers: enabled
rasterization: enabled
surface_synchronization: enabled_on
video_decode: enabled
webgl: enabled
webgl2: enabled
Load (avg) 3, 2, 2
Memory (System) 16.00GB (0.52GB free)
Process Argv
Screen Reader no
VM 0%
@nkpart
Copy link

nkpart commented Jul 2, 2019

Seeing the same issue on an Insiders build:

Commit: fe0c3e785c22c3ed2d5caa7178488c92d62bdb08
Date: 2019-06-28T12:34:48.210Z
Electron: 4.2.5
Chrome: 69.0.3497.128
Node.js: 10.11.0
V8: 6.9.427.31-electron.0
OS: Darwin x64 18.6.0
[Info] TypeError: Cannot set property 'text' of undefined
	at t.CredentialStore.willStartLogin (/home/nkpart/.vscode-server-insiders/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:358635)
	at t.CredentialStore.<anonymous> (/home/nkpart/.vscode-server-insiders/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:356720)
	at Generator.next (<anonymous>)
	at o (/home/nkpart/.vscode-server-insiders/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:354362)
	at process._tickCallback (internal/process/next_tick.js:68:7)

@RMacfarlane RMacfarlane added the bug Issue identified by VS Code Team member as probable bug label Jul 2, 2019
@Dieff
Copy link

Dieff commented Jul 11, 2019

Same issue here. I'm trying to authenticate to a Github Enterprise instance. Have tried using both Firefox and Chrome. Also using WSL remote if that makes a difference.

Version: 1.36.1 (system setup)
Commit: 2213894ea0415ee8c85c5eea0d0ff81ecc191529
Date: 2019-07-08T22:59:35.033Z
Electron: 4.2.5
Chrome: 69.0.3497.128
Node.js: 10.11.0
V8: 6.9.427.31-electron.0
OS: Windows_NT x64 10.0.16299
extension version: 0.9.0

Here is the error log:

[Info] Looking for git repository
[Info] Git repository found, initializing review manager and pr tree view.
[Info] Review> Validate state in progress
[Info] Review> Validating state...
[Info] Found GitHub remote
[Info] Error signing in to gh.******.com: TypeError: Cannot set property 'text' of undefined
[Info] TypeError: Cannot set property 'text' of undefined
	at t.CredentialStore.willStartLogin (/home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:36:357835)
	at t.CredentialStore.<anonymous> (/home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:36:355895)
	at Generator.next (<anonymous>)
	at /home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:36:353676
	at new Promise (<anonymous>)
	at n (/home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:36:353453)
	at t.CredentialStore.login (/home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:36:355690)
	at M.<anonymous> (/home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:1:362232)
	at Generator.next (<anonymous>)
	at o (/home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:1:354218)
	at process._tickCallback (internal/process/next_tick.js:68:7)
[Info] Error signing in to gh.*******.com: TypeError: Cannot set property 'text' of undefined
[Info] TypeError: Cannot set property 'text' of undefined
	at t.CredentialStore.willStartLogin (/home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:36:357835)
	at t.CredentialStore.<anonymous> (/home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:36:355895)
	at Generator.next (<anonymous>)
	at o (/home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:36:353509)
	at process._tickCallback (internal/process/next_tick.js:68:7)
[Info] Error signing in to gh.*********.com: TypeError: Cannot set property 'text' of undefined
[Info] TypeError: Cannot set property 'text' of undefined
	at t.CredentialStore.willStartLogin (/home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:36:357835)
	at t.CredentialStore.<anonymous> (/home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:36:355895)
	at Generator.next (<anonymous>)
	at o (/home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:36:353509)
	at process._tickCallback (internal/process/next_tick.js:68:7)
[Info] Error signing in to gh.**********.com: TypeError: Cannot set property 'text' of undefined
[Info] TypeError: Cannot set property 'text' of undefined
	at t.CredentialStore.willStartLogin (/home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:36:357835)
	at t.CredentialStore.<anonymous> (/home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:36:355895)
	at Generator.next (<anonymous>)
	at o (/home/ndieff/.vscode-server/extensions/github.vscode-pull-request-github-0.9.0/media/extension.js:36:353509)
	at process._tickCallback (internal/process/next_tick.js:68:7)

@RMacfarlane RMacfarlane self-assigned this Jul 12, 2019
@carloluis
Copy link

@Dieff You can authenticate the extension on GH Enterprise by:

  1. Create a new token on your https://<GH-Enterprise>/settings/tokens page

    • Select these scopes for the Token:
      • repo
      • user > read:user
      • repo > user:email
      • write:discussion
  2. Then, associate that token with the extension in settings.json:

{
  "githubPullRequests.hosts": [{
    "host": "https://<GH-Enterprise>",
    "token": "TOKEN"
  }]
}
  1. Restart the editor, and you should be able to use the GH-Pull Requests extension.

@rodion-m
Copy link

@carloluis Thank you! It works.

@iamitka
Copy link

iamitka commented Mar 30, 2020

Awesome !! Worked like a charm. :)

@cconeill
Copy link

Noting that this no longer works, the githubPullRequests.hosts config set in JSON is overwritten whenever the GitHub extension starts.

@tim-hilt
Copy link

tim-hilt commented May 8, 2020

That's right. After watching Sana and Burkes Satellite Video on YouTube, i wanted to check the extension out, but the authentication-process didn't work out for me.

~ λ code-insiders -v
1.46.0-insider
d487078dc7fc1c276657cadb61b4f63833a8df55
x64

OS is Arch Linux.


EDIT

It turns out i was missing gnome-keyring, which the extension depends on when using Linux. Installed, rebooted, tried to authenticate again. It works now, but note, that the automatic authentication from the browser didn't work out. I had to copy the token and pasted it. Apparently there are spaces added to the token (front and back) when clicking on "copy to clipboard". These spaces have to be deleted.

@carloluis
Copy link

carloluis commented Jun 8, 2020

Hi, the authentication issue is caused by the last version of the plugin since they decided to drop support for GH-Enterprise. You can read more here

As of version 0.16.0 of the extension, we are discontinuing support for GitHub Enterprise. At the beginning of this project, we had resources to test against Enterprise, but we have now been without that for quite some time.
...

If you would still like to use the extension, you can use the "Install Another Version" option from the extensions viewlet to download version 0.15.0: microsoft/vscode#12764 (comment)

I installed the previous version 0.15.0 and its working again.

image

Also discussed here on issue #1793

@eisenhowerj
Copy link

Now, we just need to figure out how to get rid of that pesky dot reminding us that Github Enterprise is an afterthought.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issue identified by VS Code Team member as probable bug
Projects
None yet
Development

No branches or pull requests

10 participants