diff --git a/build/.cachesalt b/build/.cachesalt index f5c2b5725ddbce..bd7579fd483e09 100644 --- a/build/.cachesalt +++ b/build/.cachesalt @@ -1 +1 @@ -2026-08-05T23:47:14.698Z \ No newline at end of file +2026-08-20T17:32:07.583Z \ No newline at end of file diff --git a/build/azure-pipelines/alpine/product-build-alpine-node-modules.yml b/build/azure-pipelines/alpine/product-build-alpine-node-modules.yml index 2f1423a7d1f822..a7cc0ab6f3d20b 100644 --- a/build/azure-pipelines/alpine/product-build-alpine-node-modules.yml +++ b/build/azure-pipelines/alpine/product-build-alpine-node-modules.yml @@ -61,6 +61,11 @@ jobs: condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'), ne(variables['NPM_REGISTRY'], 'none')) displayName: Setup NPM Authentication + - template: ../common/foundry-local.yml@self + parameters: + phase: prepare + onlyOnNodeModulesCacheMiss: true + - task: Docker@1 inputs: azureSubscriptionEndpoint: vscode @@ -128,6 +133,11 @@ jobs: displayName: Install dependencies condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true')) + - template: ../common/foundry-local.yml@self + parameters: + phase: install + onlyOnNodeModulesCacheMiss: true + - script: node build/azure-pipelines/common/checkNativeOptionalDeps.ts condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true')) displayName: Verify native optional dependency binaries diff --git a/build/azure-pipelines/common/foundry-local.yml b/build/azure-pipelines/common/foundry-local.yml index d40b360b8f33dc..fd9d88e8907546 100644 --- a/build/azure-pipelines/common/foundry-local.yml +++ b/build/azure-pipelines/common/foundry-local.yml @@ -4,15 +4,24 @@ parameters: values: - prepare - install + - name: onlyOnNodeModulesCacheMiss + type: boolean + default: false steps: - ${{ if eq(parameters.phase, 'prepare') }}: - task: NuGetAuthenticate@1 + ${{ if eq(parameters.onlyOnNodeModulesCacheMiss, true) }}: + condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'), ne(variables['NPM_REGISTRY'], 'none')) displayName: Setup NuGet Authentication - script: node build/azure-pipelines/common/disableFoundryLocalInstall.ts + ${{ if eq(parameters.onlyOnNodeModulesCacheMiss, true) }}: + condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'), ne(variables['NPM_REGISTRY'], 'none')) displayName: Disable Foundry Local Native Install - ${{ if eq(parameters.phase, 'install') }}: - script: node build/azure-pipelines/common/foundryLocalInstall.ts + ${{ if eq(parameters.onlyOnNodeModulesCacheMiss, true) }}: + condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'), ne(variables['NPM_REGISTRY'], 'none')) displayName: Install Foundry Local Native Dependencies diff --git a/build/azure-pipelines/darwin/product-build-darwin-node-modules.yml b/build/azure-pipelines/darwin/product-build-darwin-node-modules.yml index b4cadd1ec84189..3317e43816e990 100644 --- a/build/azure-pipelines/darwin/product-build-darwin-node-modules.yml +++ b/build/azure-pipelines/darwin/product-build-darwin-node-modules.yml @@ -75,6 +75,11 @@ jobs: condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true')) displayName: Setup PyPI Authentication + - template: ../common/foundry-local.yml@self + parameters: + phase: prepare + onlyOnNodeModulesCacheMiss: true + - script: | set -e c++ --version @@ -102,6 +107,11 @@ jobs: displayName: Install dependencies condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true')) + - template: ../common/foundry-local.yml@self + parameters: + phase: install + onlyOnNodeModulesCacheMiss: true + - script: node build/azure-pipelines/common/checkNativeOptionalDeps.ts condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true')) displayName: Verify native optional dependency binaries diff --git a/build/azure-pipelines/linux/product-build-linux-node-modules.yml b/build/azure-pipelines/linux/product-build-linux-node-modules.yml index dbcd21676665d5..ea09134e1a863d 100644 --- a/build/azure-pipelines/linux/product-build-linux-node-modules.yml +++ b/build/azure-pipelines/linux/product-build-linux-node-modules.yml @@ -82,6 +82,11 @@ jobs: condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'), ne(variables['NPM_REGISTRY'], 'none')) displayName: Setup NPM Authentication + - template: ../common/foundry-local.yml@self + parameters: + phase: prepare + onlyOnNodeModulesCacheMiss: true + - script: | set -e @@ -142,6 +147,11 @@ jobs: displayName: Install dependencies condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true')) + - template: ../common/foundry-local.yml@self + parameters: + phase: install + onlyOnNodeModulesCacheMiss: true + - script: node build/azure-pipelines/common/checkNativeOptionalDeps.ts condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true')) displayName: Verify native optional dependency binaries diff --git a/build/azure-pipelines/web/product-build-web-node-modules.yml b/build/azure-pipelines/web/product-build-web-node-modules.yml index cc61a7a015a63a..4f935de7336480 100644 --- a/build/azure-pipelines/web/product-build-web-node-modules.yml +++ b/build/azure-pipelines/web/product-build-web-node-modules.yml @@ -54,6 +54,11 @@ jobs: condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'), ne(variables['NPM_REGISTRY'], 'none')) displayName: Setup NPM Authentication + - template: ../common/foundry-local.yml@self + parameters: + phase: prepare + onlyOnNodeModulesCacheMiss: true + - script: | set -e ./build/azure-pipelines/linux/apt-retry.sh sudo apt-get update @@ -79,6 +84,11 @@ jobs: displayName: Install dependencies condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true')) + - template: ../common/foundry-local.yml@self + parameters: + phase: install + onlyOnNodeModulesCacheMiss: true + - script: node build/azure-pipelines/common/checkNativeOptionalDeps.ts condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true')) displayName: Verify native optional dependency binaries diff --git a/build/azure-pipelines/win32/product-build-win32-node-modules.yml b/build/azure-pipelines/win32/product-build-win32-node-modules.yml index eed6ebdd19925c..528a580afe3e4b 100644 --- a/build/azure-pipelines/win32/product-build-win32-node-modules.yml +++ b/build/azure-pipelines/win32/product-build-win32-node-modules.yml @@ -71,6 +71,11 @@ jobs: condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'), ne(variables['NPM_REGISTRY'], 'none')) displayName: Setup NPM Authentication + - template: ../common/foundry-local.yml@self + parameters: + phase: prepare + onlyOnNodeModulesCacheMiss: true + - powershell: | . build/azure-pipelines/win32/exec.ps1 $ErrorActionPreference = "Stop" @@ -85,6 +90,11 @@ jobs: displayName: Install dependencies condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true')) + - template: ../common/foundry-local.yml@self + parameters: + phase: install + onlyOnNodeModulesCacheMiss: true + - powershell: node build/azure-pipelines/common/checkNativeOptionalDeps.ts condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true')) displayName: Verify native optional dependency binaries diff --git a/src/vs/workbench/contrib/mcp/test/node/mcpStdioStateHandler.test.ts b/src/vs/workbench/contrib/mcp/test/node/mcpStdioStateHandler.test.ts index 0d25f80008da80..36d3cec8cfa10d 100644 --- a/src/vs/workbench/contrib/mcp/test/node/mcpStdioStateHandler.test.ts +++ b/src/vs/workbench/contrib/mcp/test/node/mcpStdioStateHandler.test.ts @@ -9,7 +9,9 @@ import * as assert from 'assert'; import { McpStdioStateHandler } from '../../node/mcpStdioStateHandler.js'; import { isWindows } from '../../../../../base/common/platform.js'; -const GRACE_TIME = 100; +// Must be comfortably larger than the time it takes to spawn the helper shell +// script that signals the process tree, otherwise SIGKILL can race SIGTERM. +const GRACE_TIME = 1000; suite('McpStdioStateHandler', () => { const store = ensureNoDisposablesAreLeakedInTestSuite(); @@ -75,7 +77,9 @@ suite('McpStdioStateHandler', () => { }); } - test('sigkill after grace', async () => { + test('sigkill after grace', async function () { + this.timeout(GRACE_TIME * 10); + const { handler, output } = run(` setInterval(() => {}, 1000); process.stdin.on('end', () => process.stdout.write('stdin ended\\n'));