Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
a9977fd
dom: batch DisposableResizeObserver via rAF + convert raw call sites
bryanchen-d May 5, 2026
4b39c53
test: add DisposableResizeObserver batching/dispose tests
bryanchen-d May 5, 2026
e71769c
test: inject ResizeObserver ctor instead of mutating mainWindow
bryanchen-d May 5, 2026
1995a3e
docs: capture DI-over-global-stub testing learning in copilot-instruc…
bryanchen-d May 5, 2026
1f27933
dom: revert DisposableResizeObserver to sync, add loop-warning attrib…
bryanchen-d May 5, 2026
2613d4a
dom: attribute ResizeObserver loop warning to DisposableResizeObserve…
bryanchen-d May 5, 2026
0c4d442
dom test: swallow expected onUnexpectedError in throwing-callback test
bryanchen-d May 5, 2026
0267282
adding request.options.tools event to 3p
24anisha May 6, 2026
78f5870
add logs for unexpected InstancePolicy.prompt in sessions window
benibenj May 6, 2026
4fa056e
multiplex in case it's too long
24anisha May 6, 2026
5aad0a4
dom: scope DisposableResizeObserver attribution to the same task via …
bryanchen-d May 6, 2026
99e7a43
add tests
24anisha May 6, 2026
e75e0d3
Merge branch 'main' into anisha/request_tools_3p
24anisha May 6, 2026
803ca35
Show relative pricing in model picker (#314541)
pwang347 May 6, 2026
c17280f
chat: add copy microinteraction to code blocks (#314750)
hawkticehurst May 6, 2026
e7ba495
dom: scope DisposableResizeObserver attribution to the same task via …
bryanchen-d May 6, 2026
144d32f
Merge branch 'main' into brchen/resize-observer-loop-batch
bryanchen-d May 6, 2026
3d58420
Merge pull request #314411 from microsoft/brchen/resize-observer-loop…
bryanchen-d May 6, 2026
e7ba541
Merge pull request #314776 from microsoft/benibenj/alert-tiglon
benibenj May 6, 2026
033f600
chore: bump sanity test containers (#314778)
rzhao271 May 6, 2026
186edb0
chat: Discover plugins installed by Copilot CLI (#314805)
joshspicer May 6, 2026
e8d8f5f
Chat terminal: detect sensitive prompts and surface focus-terminal UI…
meganrogge May 6, 2026
1cd7c1c
Reasoning effort and context picker updates (#314823)
pwang347 May 6, 2026
c498c28
Strip NODE_OPTIONS in removeDangerousEnvVariables (#314847)
meganrogge May 6, 2026
28704d8
Integrated terminal - fix stale OSC 8 link hover tooltip issues (#309…
JeffreyCA May 6, 2026
ddaad83
chat: use ILabelService for remote agent host names in permission UI …
connor4312 May 6, 2026
d365bcb
sessions: retain attached editor maximize state (#314841)
hawkticehurst May 6, 2026
c2a4260
Terminate COM surrogate process before update/gc (#313791)
dmitrivMS May 6, 2026
21b561c
agent-host: restore selected model in picker (#314613)
roblourens May 6, 2026
2f36dfd
mcp: use chatStreamToolCallId for tool invocation permalinks (#314870)
connor4312 May 6, 2026
0bc0832
Fix setup localization files encoding (#312073)
dmitrivMS May 6, 2026
a906972
Merge pull request #314641 from microsoft/anisha/request_tools_3p
24anisha May 6, 2026
a0e2d70
Agent Host: Show Open Pull Request button + live PR/CI state (#314860)
roblourens May 6, 2026
79ca5c3
sessions: match panel tabs to auxiliary bar (#314843)
hawkticehurst May 6, 2026
468fa08
Don't skip quota bucket when hasQuota: false (#314874)
pwang347 May 6, 2026
c9b1f88
agentHost/claude: Phase 5 + Phase 6 — IAgent provider, sendMessage (r…
TylerLeonhardt May 6, 2026
e1615a4
Agent host: prefer origin/<default> as worktree base (#314861)
roblourens May 6, 2026
e5ed664
Update look of model hover (#314820)
pwang347 May 7, 2026
2c6eb47
Fix agent host config picker order: worktree first, branch second (#3…
roblourens May 7, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/copilot-instructions.md
Original file line number Diff line number Diff line change
Expand Up @@ -150,3 +150,4 @@ function f(x: number, y: string): void { }

## Learnings
- Minimize the amount of assertions in tests. Prefer one snapshot-style `assert.deepStrictEqual` over multiple precise assertions, as they are much more difficult to understand and to update.
- Do not stub a global object (e.g. `(mainWindow as any).ResizeObserver = ...`) or use `any` casts to install fakes in tests. Instead, make the dependency injectable: add an optional constructor parameter on the production class that defaults to the real implementation (e.g. `targetWindow.ResizeObserver`), and have the test pass a fake that implements the real interface.
48 changes: 24 additions & 24 deletions build/azure-pipelines/product-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -525,32 +525,32 @@ extends:
container: centos
arch: arm64

# Debian 10
# Debian 11
- ${{ if eq(parameters.VSCODE_BUILD_LINUX, true) }}:
- template: build/azure-pipelines/common/sanity-tests.yml@self
parameters:
name: debian_10_amd64
displayName: Debian 10 amd64
name: debian_11_amd64
displayName: Debian 11 amd64
poolName: 1es-ubuntu-22.04-x64
container: debian-10
container: debian-11
arch: amd64

- ${{ if eq(parameters.VSCODE_BUILD_LINUX_ARMHF, true) }}:
- template: build/azure-pipelines/common/sanity-tests.yml@self
parameters:
name: debian_10_arm32
displayName: Debian 10 arm32
name: debian_11_arm32
displayName: Debian 11 arm32
poolName: 1es-azure-linux-3-arm64
container: debian-10
container: debian-11
arch: arm

- ${{ if eq(parameters.VSCODE_BUILD_LINUX_ARM64, true) }}:
- template: build/azure-pipelines/common/sanity-tests.yml@self
parameters:
name: debian_10_arm64
displayName: Debian 10 arm64
name: debian_11_arm64
displayName: Debian 11 arm64
poolName: 1es-azure-linux-3-arm64
container: debian-10
container: debian-11
arch: arm64

# Debian 12
Expand Down Expand Up @@ -581,42 +581,42 @@ extends:
container: debian-12
arch: arm64

# Fedora 36
# Fedora 42
- ${{ if eq(parameters.VSCODE_BUILD_LINUX, true) }}:
- template: build/azure-pipelines/common/sanity-tests.yml@self
parameters:
name: fedora_36_amd64
displayName: Fedora 36 amd64
name: fedora_42_amd64
displayName: Fedora 42 amd64
poolName: 1es-ubuntu-22.04-x64
container: fedora-36
container: fedora-42
arch: amd64

- ${{ if eq(parameters.VSCODE_BUILD_LINUX_ARM64, true) }}:
- template: build/azure-pipelines/common/sanity-tests.yml@self
parameters:
name: fedora_36_arm64
displayName: Fedora 36 arm64
name: fedora_42_arm64
displayName: Fedora 42 arm64
poolName: 1es-azure-linux-3-arm64
container: fedora-36
container: fedora-42
arch: arm64

# Fedora 40
# Fedora 43
- ${{ if eq(parameters.VSCODE_BUILD_LINUX, true) }}:
- template: build/azure-pipelines/common/sanity-tests.yml@self
parameters:
name: fedora_40_amd64
displayName: Fedora 40 amd64
name: fedora_43_amd64
displayName: Fedora 43 amd64
poolName: 1es-ubuntu-22.04-x64
container: fedora-40
container: fedora-43
arch: amd64

- ${{ if eq(parameters.VSCODE_BUILD_LINUX_ARM64, true) }}:
- template: build/azure-pipelines/common/sanity-tests.yml@self
parameters:
name: fedora_40_arm64
displayName: Fedora 40 arm64
name: fedora_43_arm64
displayName: Fedora 43 arm64
poolName: 1es-azure-linux-3-arm64
container: fedora-40
container: fedora-43
arch: arm64

# openSUSE Leap 16.0
Expand Down
48 changes: 24 additions & 24 deletions build/azure-pipelines/product-sanity-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -128,29 +128,29 @@ extends:
container: centos
arch: arm64

# Debian 10
# Debian 11
- template: build/azure-pipelines/common/sanity-tests.yml@self
parameters:
name: debian_10_amd64
displayName: Debian 10 amd64
name: debian_11_amd64
displayName: Debian 11 amd64
poolName: 1es-ubuntu-22.04-x64
container: debian-10
container: debian-11
arch: amd64

- template: build/azure-pipelines/common/sanity-tests.yml@self
parameters:
name: debian_10_arm32
displayName: Debian 10 arm32
name: debian_11_arm32
displayName: Debian 11 arm32
poolName: 1es-azure-linux-3-arm64
container: debian-10
container: debian-11
arch: arm

- template: build/azure-pipelines/common/sanity-tests.yml@self
parameters:
name: debian_10_arm64
displayName: Debian 10 arm64
name: debian_11_arm64
displayName: Debian 11 arm64
poolName: 1es-azure-linux-3-arm64
container: debian-10
container: debian-11
arch: arm64

# Debian 12
Expand Down Expand Up @@ -178,38 +178,38 @@ extends:
container: debian-12
arch: arm64

# Fedora 36
# Fedora 42
- template: build/azure-pipelines/common/sanity-tests.yml@self
parameters:
name: fedora_36_amd64
displayName: Fedora 36 amd64
name: fedora_42_amd64
displayName: Fedora 42 amd64
poolName: 1es-ubuntu-22.04-x64
container: fedora-36
container: fedora-42
arch: amd64

- template: build/azure-pipelines/common/sanity-tests.yml@self
parameters:
name: fedora_36_arm64
displayName: Fedora 36 arm64
name: fedora_42_arm64
displayName: Fedora 42 arm64
poolName: 1es-azure-linux-3-arm64
container: fedora-36
container: fedora-42
arch: arm64

# Fedora 40
# Fedora 43
- template: build/azure-pipelines/common/sanity-tests.yml@self
parameters:
name: fedora_40_amd64
displayName: Fedora 40 amd64
name: fedora_43_amd64
displayName: Fedora 43 amd64
poolName: 1es-ubuntu-22.04-x64
container: fedora-40
container: fedora-43
arch: amd64

- template: build/azure-pipelines/common/sanity-tests.yml@self
parameters:
name: fedora_40_arm64
displayName: Fedora 40 arm64
name: fedora_43_arm64
displayName: Fedora 43 arm64
poolName: 1es-azure-linux-3-arm64
container: fedora-40
container: fedora-43
arch: arm64

# openSUSE Leap 16.0
Expand Down
17 changes: 1 addition & 16 deletions build/gulpfile.vscode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -714,21 +714,6 @@ BUILD_TARGETS.forEach(buildTarget => {

// #region nls

const innoSetupConfig: Record<string, { codePage: string; defaultInfo?: { name: string; id: string } }> = {
'zh-cn': { codePage: 'CP936', defaultInfo: { name: 'Simplified Chinese', id: '$0804', } },
'zh-tw': { codePage: 'CP950', defaultInfo: { name: 'Traditional Chinese', id: '$0404' } },
'ko': { codePage: 'CP949', defaultInfo: { name: 'Korean', id: '$0412' } },
'ja': { codePage: 'CP932' },
'de': { codePage: 'CP1252' },
'fr': { codePage: 'CP1252' },
'es': { codePage: 'CP1252' },
'ru': { codePage: 'CP1251' },
'it': { codePage: 'CP1252' },
'pt-br': { codePage: 'CP1252' },
'hu': { codePage: 'CP1250' },
'tr': { codePage: 'CP1254' }
};

gulp.task(task.define(
'vscode-translations-export',
task.series(
Expand Down Expand Up @@ -758,7 +743,7 @@ gulp.task('vscode-translations-import', function () {
return es.merge([...i18n.defaultLanguages, ...i18n.extraLanguages].map(language => {
const id = language.id;
return gulp.src(`${options.location}/${id}/vscode-setup/messages.xlf`)
.pipe(i18n.prepareIslFiles(language, innoSetupConfig[language.id]))
.pipe(i18n.prepareIslFiles(language))
.pipe(vfs.dest(`./build/win32/i18n`));
}));
});
Expand Down
4 changes: 4 additions & 0 deletions build/gulpfile.vscode.win32.ts
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,10 @@ function buildWin32Setup(arch: string, target: string): task.CallbackTask {
definitions['AppxPackage'] = `${quality === 'stable' ? 'code' : 'code_insider'}_${arch}.appx`;
definitions['AppxPackageDll'] = `${quality === 'stable' ? 'code' : 'code_insider'}_explorer_command_${arch}.dll`;
definitions['AppxPackageName'] = `${product.win32AppUserModelId}`;
const ctxMenu = (product as { win32ContextMenu?: Record<string, { clsid: string }> }).win32ContextMenu;
if (ctxMenu && ctxMenu[arch]) {
definitions['FileExplorerContextMenuCLSID'] = ctxMenu[arch].clsid;
}
}

fs.writeFileSync(productJsonPath, JSON.stringify(productJson, undefined, '\t'));
Expand Down
22 changes: 12 additions & 10 deletions build/lib/i18n.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import xml2js from 'xml2js';
import gulp from 'gulp';
import fancyLog from 'fancy-log';
import ansiColors from 'ansi-colors';
import iconv from '@vscode/iconv-lite-umd';
import { type l10nJsonFormat, getL10nXlf, type l10nJsonDetails, getL10nFilesFromXlf, getL10nJson } from '@vscode/l10n-dev';

const REPO_ROOT_PATH = path.join(import.meta.dirname, '../..');
Expand All @@ -27,10 +26,6 @@ export interface Language {
folderName?: string; // language specific folder name, e.g. cht, deu (optional, if not set, the id is used)
}

export interface InnoSetup {
codePage: string; //code page for encoding (http://www.jrsoftware.org/ishelp/index.php?topic=langoptionssection)
}

export const defaultLanguages: Language[] = [
{ id: 'zh-tw', folderName: 'cht', translationId: 'zh-hant' },
{ id: 'zh-cn', folderName: 'chs', translationId: 'zh-hans' },
Expand Down Expand Up @@ -128,6 +123,11 @@ class TextModel {
private _lines: string[];

constructor(contents: string) {
// Strip a leading UTF-8 BOM (U+FEFF) so callers can match on the
// first character of the first line without having to special-case it.
if (contents.charCodeAt(0) === 0xFEFF) {
contents = contents.slice(1);
}
this._lines = contents.split(/\r\n|\r|\n/);
}

Expand Down Expand Up @@ -798,7 +798,7 @@ export function prepareI18nPackFiles(resultingTranslationPaths: TranslationPath[
});
}

export function prepareIslFiles(language: Language, innoSetupConfig: InnoSetup): eventStream.ThroughStream {
export function prepareIslFiles(language: Language): eventStream.ThroughStream {
const parsePromises: Promise<l10nJsonDetails[]>[] = [];

return eventStream.through(function (this: eventStream.ThroughStream, xlf: File) {
Expand All @@ -808,7 +808,7 @@ export function prepareIslFiles(language: Language, innoSetupConfig: InnoSetup):
parsePromise.then(
resolvedFiles => {
resolvedFiles.forEach(file => {
const translatedFile = createIslFile(file.name, file.messages, language, innoSetupConfig);
const translatedFile = createIslFile(file.name, file.messages, language);
stream.queue(translatedFile);
});
}
Expand All @@ -824,7 +824,7 @@ export function prepareIslFiles(language: Language, innoSetupConfig: InnoSetup):
});
}

function createIslFile(name: string, messages: l10nJsonFormat, language: Language, innoSetup: InnoSetup): File {
function createIslFile(name: string, messages: l10nJsonFormat, language: Language): File {
const content: string[] = [];
let originalContent: TextModel;
if (path.basename(name) === 'Default') {
Expand Down Expand Up @@ -855,11 +855,13 @@ function createIslFile(name: string, messages: l10nJsonFormat, language: Languag

const basename = path.basename(name);
const filePath = `${basename}.${language.id}.isl`;
const encoded = iconv.encode(Buffer.from(content.join('\r\n'), 'utf8').toString(), innoSetup.codePage);
const utf8BOM = Buffer.from([0xEF, 0xBB, 0xBF]);
const contentBuffer = Buffer.from(content.join('\r\n'), 'utf8');
const encoded = Buffer.concat([utf8BOM, contentBuffer]);

return new File({
path: filePath,
contents: Buffer.from(encoded),
contents: encoded,
});
}

Expand Down
29 changes: 29 additions & 0 deletions build/win32/code.iss
Original file line number Diff line number Diff line change
Expand Up @@ -1718,6 +1718,32 @@ begin
Result := False;
end;

// Unblock inno_updater --gc when our context-menu COM surrogate keeps a
// handle on the orphan commit folder. See https://github.com/microsoft/vscode/issues/294546.
// No-op when FileExplorerContextMenuCLSID is not defined (e.g. OSS builds).
procedure KillContextMenuComSurrogate();
var
KillErrorCode: Integer;
Command: String;
begin
#ifdef FileExplorerContextMenuCLSID
Log('KillContextMenuComSurrogate: stopping COM surrogate(s) hosting context-menu DLL ({#FileExplorerContextMenuCLSID})');

Command :=
'-NoLogo -NoProfile -NonInteractive -WindowStyle Hidden -ExecutionPolicy Bypass -Command "' +
'Get-CimInstance Win32_Process -Filter ""Name = ''dllhost.exe''"" | ' +
'Where-Object { $_.CommandLine -like ''*/Processid:{#FileExplorerContextMenuCLSID}*'' } | ' +
'ForEach-Object { try { Stop-Process -Id $_.ProcessId -Force -ErrorAction Stop } catch {} }"';

if not ShellExec('', 'powershell.exe', Command, '', SW_HIDE, ewWaitUntilTerminated, KillErrorCode) then
Log('KillContextMenuComSurrogate: ShellExec failed with error code ' + IntToStr(KillErrorCode))
else if KillErrorCode <> 0 then
Log('KillContextMenuComSurrogate: PowerShell exited with non-zero code ' + IntToStr(KillErrorCode))
else
Log('KillContextMenuComSurrogate: complete');
#endif
end;

#ifdef AppxPackageName
var
AppxPackageFullname: String;
Expand Down Expand Up @@ -1776,6 +1802,7 @@ procedure RemoveAppxPackage();
var
RemoveAppxPackageResultCode: Integer;
begin
KillContextMenuComSurrogate();
// Remove the old context menu package
// Following condition can be removed in v1.111.
if QualityIsInsiders() and not SessionEndFileExists() and AppxPackageInstalled('Microsoft.VSCodeInsiders', RemoveAppxPackageResultCode) then begin
Expand Down Expand Up @@ -1860,6 +1887,7 @@ begin
Log('inno_updater completed successfully');
#if "system" == InstallTarget
if IsVersionedUpdate() then begin
KillContextMenuComSurrogate();
Log('Invoking inno_updater to remove previous installation folder');
Exec(ExpandConstant('{app}\{#VersionedResourcesFolder}\tools\inno_updater.exe'), ExpandConstant('"--gc" "{app}\{#ExeBasename}.exe" "{#VersionedResourcesFolder}" "{#ExeBasename}.exe"' {#ifdef ProxyExeBasename} + ' "{#ProxyExeBasename}.exe"' {#endif}), '', SW_SHOW, ewWaitUntilTerminated, UpdateResultCode);
Log('inno_updater completed gc successfully');
Expand All @@ -1870,6 +1898,7 @@ begin
end;
end else begin
if IsVersionedUpdate() then begin
KillContextMenuComSurrogate();
Log('Invoking inno_updater to remove previous installation folder');
Exec(ExpandConstant('{app}\{#VersionedResourcesFolder}\tools\inno_updater.exe'), ExpandConstant('"--gc" "{app}\{#ExeBasename}.exe" "{#VersionedResourcesFolder}" "{#ExeBasename}.exe"' {#ifdef ProxyExeBasename} + ' "{#ProxyExeBasename}.exe"' {#endif}), '', SW_SHOW, ewWaitUntilTerminated, UpdateResultCode);
Log('inno_updater completed gc successfully');
Expand Down
Loading
Loading