Commit Graph

297 Commits

Author SHA1 Message Date
Copilot
b2590e0b22 Fix FetcherService retrying with multiple fetchers on 429 and other application errors (#282100)
* Initial plan

* Fix FetcherService to not retry with other fetchers on 429 status code

Co-authored-by: TylerLeonhardt <2644648+TylerLeonhardt@users.noreply.github.com>

* Improve test robustness based on code review feedback

Co-authored-by: TylerLeonhardt <2644648+TylerLeonhardt@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TylerLeonhardt <2644648+TylerLeonhardt@users.noreply.github.com>
2025-12-10 01:57:09 +00:00
Tyler James Leonhardt
55d06aa3a1 Add a log for the url (#282098)
so it's clear what fails. We saw rate limiting from GH EDU.
2025-12-08 16:51:11 -08:00
Raymond Zhao
41997d514d chore: npm audit fix (#279437)
* chore: npm audit fix

* chore: npm audit fix in extensions

* chore: npm audit fix in tests

* Catch last few
2025-11-25 20:29:09 +00:00
Paul
55cdeb5771 Add prefer device flow config for GitHub auth (#271838)
* Initial plan

* Add forceDeviceCodeFlow setting for GitHub authentication

Co-authored-by: pwang347 <8560030+pwang347@users.noreply.github.com>

* modifications

* nit

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: pwang347 <8560030+pwang347@users.noreply.github.com>
2025-10-17 00:06:01 +00:00
Matt Bierner
162806006a Update a few package-locks for mocha 2025-10-13 11:13:12 -07:00
Matt Bierner
98b069c041 Work towards getting isolated built-in extension compiles
For #271167

This makes it so our built-in extensions can mostly be built using `tsc` on the command line. Previously the extensions were picking up a lot of typing info from the root `node_modules` that meant they weren't truly independent
2025-10-13 11:03:20 -07:00
Tyler James Leonhardt
8845fc4b5c Remove any casts in auth extensions (#270089) 2025-10-06 12:28:27 -07:00
Matt Bierner
360c9fd134 Add lint rule for as any and bulk ignore all existing breaks
For #269213

This adds a new eslint rule for `as any` and `<any>({... })`. We'd like to remove almost all of these, however right now the first goal is to prevent them in new code. That's why with this first PR I simply add `eslint-disable` comments for all breaks

Trying to get this change in soon after branching off for release to hopefully minimize disruption during debt week work
2025-10-02 23:38:33 -07:00
Tyler James Leonhardt
2deaa78bcf Add /login/oauth path part to the ghes supported authorization server (#265703)
Fixes GHE MCP loading
2025-09-08 17:38:49 +00:00
Christof Marti
f5f2ea58fc Rerun fallbacks (#260297) 2025-09-08 16:55:43 +02:00
Tyler James Leonhardt
71b461ab86 Support PKCE for GitHub Auth (#265381)
Fixes https://github.com/microsoft/vscode/issues/264795
2025-09-05 19:55:35 +02:00
Christof Marti
7be2a0b2e6 Retry with first fetcher to avoid fallback on resume 2025-09-04 21:42:15 +02:00
Benjamin Pasero
d44d16c464 Wire in a auth callback parameter to indicate Copilot terms were shown to the user (microsoft/vscode-internalbacklog#5761) (#262439)
* implement as a bag

* nit

---------

Co-authored-by: TylerLeonhardt <2644648+TylerLeonhardt@users.noreply.github.com>
2025-08-22 14:42:25 +09:00
Christof Marti
5bf6e4d607 Fall back to alternate fetch implementation (#262181) 2025-08-19 04:46:22 -07:00
Tyler James Leonhardt
d3c3cf8f50 Attempt to fix Codespaces bug by declaring a default (#261484)
Fixes https://github.com/microsoft/vscode/issues/261238
2025-08-13 16:44:28 +00:00
Copilot
97bc9a439c Fix GitHub Authentication reload dialog appearing unnecessarily in remote tunnel scenarios (#261257) 2025-08-12 09:47:23 -07:00
Tyler James Leonhardt
631a4d9dbb Workaround electron proxy issues for GitHub by allowing to switch to node's fetch (#261099)
A user reported that their proxy ZScaller has issues with Electron's fetch. More research needs to be done to understand why this is not playing nice wholistically...

... but, to unblock GitHub scenarios like Copilot, we add this setting to change the implementation of fetch used.

At some point, we need to have http.useElectronFetch setting be enabled by default and when that happens, this setting can be removed in favor of that.

cc @chrmarti @alexdima
2025-08-11 18:39:45 +00:00
Matt Bierner
ed71020bfc Convert extension webpack scripts to modules 2025-08-07 17:20:22 -07:00
Matt Bierner
d8c9852fe9 Don't use experimental decorators in extensions
Seeing if we can compile our extensions using TS native which doesn't support these. The usage is so low that I think we can just remove them
2025-08-06 13:24:19 -07:00
Benjamin Pasero
2188c90df5 Add sign in option for Apple (microsoft/vscode-internalbacklog#5578) (#255155) 2025-07-10 14:43:10 -07:00
Tyler James Leonhardt
8bd52a173e Redirect to vscode.dev/redirect and then vscode://.... (#254841)
So that the browser remembers who triggered the redirect.

Fixes https://github.com/microsoft/vscode/issues/254810
2025-07-09 12:33:37 +02:00
Tyler James Leonhardt
b1e40f2893 Revert "Use Code OSS GitHub client id" (#252559) 2025-06-26 18:04:50 -07:00
Lee Murray
e0233e7545 Add insiders filter support in CSS and update variables dynamically (#252488)
Co-authored-by: lemurra_microsoft <Lee.Murray@microsoft.com>
2025-06-26 21:09:15 +02:00
Tyler James Leonhardt
8d05b579cc Use Code OSS GitHub client id (#252426)
To separate Code OSS & VS Code.
2025-06-25 18:58:58 +02:00
Benjamin Pasero
b8aaad0ef8 auth - update animation (#251939) 2025-06-19 20:57:09 +02:00
Benjamin Pasero
a6c11ed472 auth - modernise local redirect page (#251895) 2025-06-19 16:56:55 +02:00
Tyler James Leonhardt
51eba2dc05 Support provider parameter in device code flow (#251767)
Not lit up on the server side, but should be ready in the next day or so.
2025-06-18 03:20:41 +02:00
Tyler James Leonhardt
559c2fa308 Use provider query parameter (#251662)
The identity team are gonna take this direction instead.
2025-06-17 18:06:36 +02:00
Tyler James Leonhardt
2fabac413d Introduce auth-provider specific props & use it for social sign in for GitHub (#251649)
ref https://github.com/microsoft/vscode/issues/251648

NOTE: the server side is not quite ready. It doesn't redirect back to VS Code properly, but this should be good to go whenever that is.
2025-06-16 23:02:36 +02:00
Copilot
5a501dcde9 Add light mode support to GitHub authentication sign-in page (#251509)
* Initial plan for issue

* Add light mode support to GitHub auth page using CSS media queries

Co-authored-by: TylerLeonhardt <2644648+TylerLeonhardt@users.noreply.github.com>

* use vscode colors

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TylerLeonhardt <2644648+TylerLeonhardt@users.noreply.github.com>
Co-authored-by: Tyler Leonhardt <tyleonha@microsoft.com>
2025-06-15 23:27:27 -07:00
Tyler James Leonhardt
5d83e82b2d Fix name branding (#251566)
* Fix name branding

Typo...

* one more fix

* move around
2025-06-16 05:41:57 +00:00
Tyler James Leonhardt
9cbcaa893f Bring in branding when built (#251451)
* Bring in branding when built

Since we shouldn't have "Visual Studio Code" in this OSS repo.

* fix test
2025-06-13 16:41:29 -07:00
Tyler James Leonhardt
31620a3dec Have Loopback Server flow redirect back to VS Code and make it the primary flow (#251333)
* Have Loopback Server flow redirect back to VS Code and make it the primary flow

Fixes https://github.com/microsoft/vscode/issues/250086

* Fix test

* Fix test

* Fix other test
2025-06-13 08:14:41 +02:00
Tyler James Leonhardt
89fbfc20ab Fix race condition in unregistering authentication providers (#250667)
A minimal change for endgame.
2025-06-04 13:35:13 -07:00
Tyler James Leonhardt
c235626145 issuer -> authorizationServer refactor (#250359)
* `issuer` -> `authorizationServer` refactor

Also:
* adds `authorizationServerGlobs` to the authentication contribution schema
* removes ugly MCP issuer hack and instead plumbs the authorizationServer down to the new auth providers
2025-06-02 17:38:21 -07:00
Tyler James Leonhardt
86efdcd2c1 Introduce Issuer handling in the Authentication stack (#248948)
Mostly plumbing... this enables:
```
vscode.authentication.getSession('microsoft', scopes, { issuer: "https://login.microsoftonline.com/common/v2.0" });
```
And the respective API for an auth providers to handle it being passed in.

This props up work in MCP land which needs a way to map an issuer to an auth provider... but I certainly see utility outside of that space.

Fixes https://github.com/microsoft/vscode/issues/248775#issuecomment-2876711396
2025-05-14 23:02:15 +02:00
Tyler James Leonhardt
a1d4a24624 Register a NullAuthProvider for github-enterprise when there is no setting set (#248870)
This should help in some cases where extensions call getSession to get github-enterprise and end up waiting 5 seconds for it to time out because it use to only be registered when there was a setting set.
2025-05-13 16:24:14 -07:00
Tyler James Leonhardt
b2224f2fc6 Improve logic for detection of node vs web worker extension host (#248534)
* Use `WorkerGlobalScope` instead of `navigator` since node defines `navigator` now

* microsoft auth too

* better logic
2025-05-09 19:37:27 +02:00
Robo
12326f9906 chore: update to Electron 35 (#245423)
* chore: bump electron@35.0.1

* chore: update types/node@22.x

* chore: update web types for node v22.x

* chore: bump electron@35.1.2

* chore: update node.js build

* chore: update app.dock usage

Refs 71f3ff6bf2

* chore: bump electron@35.1.4

* chore: bump electron@35.1.5

* ci: bump sysroot to glibc 2.28 and gcc 10.5.0

* ci: enable timeout for smoketests

* chore: bump min glibcxx to 3.4.26 for server

* Revert "ci: enable timeout for smoketests"

This reverts commit afb637e85d.

* chore: update debian dependencies

* fix: workaround npm.ps1 argument parsing with powershell

* chore: update rpm dependencies

* test: partially revert changes from 242535

* test: remove redudant keybinding dispatch for selectTab

* test: fix test failure from running configured tasks

* test: focus settings editor for preferences.test.ts

* node - adopt compile cache (#246835)

* node - adopt compile cache

* adopt for utility process

* tweaks

* log state of compilation cache

* Revert "log state of compilation cache"

This reverts commit f3840387a583013834762e2c44f6e8424929297f.

* Revert "node - adopt compile cache (#246835)"

This reverts commit 673a00cab66c9bac87f3cd27b80efa41c80150f1.

* chore: update builds

* chore: bump electron@35.2.0

* chore: bump electron@35.2.1

* chore: bump electron@35.2.2

---------

Co-authored-by: Benjamin Pasero <benjamin.pasero@microsoft.com>
2025-05-09 19:03:36 +09:00
Tyler James Leonhardt
9ca1204521 Doc calling out GitHub OAuth client secret behavior (#242210) 2025-02-27 18:47:41 +01:00
Tyler James Leonhardt
d5f4a77e00 GitHub Enterprise GHE.com Setting clarity (#240289)
And a pattern to make sure no one puts a DotCom URL.

ref https://github.com/microsoft/vscode-pull-request-github/issues/6602
2025-02-10 20:35:06 +01:00
Devraj Mehta
63d1401dee fix: add electron as an external for webpack (#239134)
* fix: add electron as an external for webpack

* refactor: move electron external to shared webpack
2025-02-03 18:54:18 +00:00
Devraj Mehta
87ed97df8b Use Electron fetch or Node fetch for github-authentication to support proxies (#238149)
* Attempt to use Electron fetch for github-authentication

Also changes fallback from node-fetch to the built-in Node fetch

* Remove Content-Length header Electron compatibility

It looks like it was set incorrectly to the body contents anyways.
2025-01-17 19:05:10 +00:00
Logan Ramos
e689b912ba Update telemetry package (#236378) 2024-12-17 20:12:49 +01:00
Tyler James Leonhardt
950b401a9c Make multiple accounts the default (#231618) 2024-10-18 01:36:06 +02:00
Tyler James Leonhardt
6d482e38cd No longer look at sessions[0] (#231063)
We don't need to do this anymore now that account preference is kept across sessions.
2024-10-10 14:50:19 -07:00
Robo
9494a89080 chore: add npmrc to extensions folder (#230214) 2024-10-01 12:43:01 +02:00
Tyler James Leonhardt
52b0ec07b8 Allow Multi-account in GitHub Auth in Insiders (#229106) 2024-09-20 00:31:40 +02:00
Tyler James Leonhardt
c4d1cc2e67 Fix GitHub account ids being numbers (#228045)
For a long time the account id wasn't handled correctly. It should be a string, but the API returns a number. This ensures it's a string and does some migration logic.
2024-09-10 04:39:37 +02:00
hj
88d7b97c93 chore: rm unreached ignore items when build extensions. (#227906)
chore: rm unreached ignore items when compiling extensions.
2024-09-09 10:32:51 +00:00