Skip to content

Allow extension to use OAuth on VS Code in the browser

Following the recently merged basic OAuth implementation for GitLab Workflow (VS Code Extension) which allows using the VS Code extension without generating a token, trying to use this on VS Code in the browser fails with an error:

The redirect URI included is not valid.

Error in screenshot
Screenshot_2023-03-07_at_21.35.44

The example above can be reproduced in a Gitpod.io workspace.

From a relevant issue in https://github.com/gitpod-io/gitpod/issues/15186 describing the problem, here are two things that could be fixed on the GitLab side:

  1. whitelist url callbacks so it works on web
  2. use vscode.env.asExternalUri api in their extension

Cc @jeanp413 @filiptronicek

Edited by George Tsiolis