Skip to content

Env vars from one configuration bleed into another #83187

@StephenWeatherford

Description

@StephenWeatherford

Issue Type: Bug

I've seen this multiple times but when I tried to come up with a repro it wasn't consistent. I've got an environment variable DISABLE_SLOW tests defined as "1" in one configuration but not in a second. After using the first configuration for a while, then switching to the second, I'm finding that DISABLE_SLOW is stilled set to the value "1" from the first configuration even though it's not set at all in the second.

EXPECTED: Env vars set in one configuration shouldn't hang around and affect another.

Here are my configurations from launch.json:

        {
            "name": "Launch Tests",
            "type": "extensionHost",
            "request": "launch",
            "runtimeExecutable": "${execPath}",
            "args": [
                "--extensionDevelopmentPath=${workspaceFolder}",
                "--extensionTestsPath=${workspaceFolder}/out/test"
            ],
            "stopOnEntry": false,
            "sourceMaps": true,
            // outFiles is used for locating generated JavaScript files, see https://code.visualstudio.com/docs/nodejs/nodejs-debugging#_source-maps
            "outFiles": [
                "${workspaceFolder}/out/**/*.js"
            ],
            "preLaunchTask": "npm: compile",
            "env": {
                "MOCHA_grep": "", // RegExp of tests to run (empty for all)
                "MOCHA_invert": "0", // Invert the RegExp
                "AZCODE_ARM_IGNORE_BUNDLE": "1",
                "MOCHA_enableTimeouts": "0", // Disable time-outs
                "DEBUGTELEMETRY": "1", // 1=quiet; verbose=see telemetry in console; 0=send telemetry
                "NODE_DEBUG": "",
                "DISABLE_LANGUAGE_SERVER_TESTS": "0",
                "DISABLE_SLOW_TESTS": "1"
            }
        },
        {
            "name": "Launch Tests (webpack)",
            "type": "extensionHost",
            "request": "launch",
            "runtimeExecutable": "${execPath}",
            "args": [
                "--extensionDevelopmentPath=${workspaceFolder}",
                "--extensionTestsPath=${workspaceFolder}/dist/test"
            ],
            "stopOnEntry": false,
            "sourceMaps": true,
            // outFiles is used for locating generated JavaScript files, see https://code.visualstudio.com/docs/nodejs/nodejs-debugging#_source-maps
            "outFiles": [
                "${workspaceFolder}/dist/**/*.js"
            ],
            "preLaunchTask": "npm: pretest-dev",
            "env": {
                "MOCHA_grep": "", // RegExp of tests to run (empty for all)
                "MOCHA_invert": "0", // Invert the RegExp
                "MOCHA_enableTimeouts": "0", // Disable time-outs
                "DEBUGTELEMETRY": "1", // 1=quiet; verbose=see telemetry in console; 0=send telemetry
                "NODE_DEBUG": "",
                "AZCODE_ARM_IGNORE_BUNDLE": "0"
            }
        }

VS Code version: Code - Insiders 1.40.0-insider (c58aaab, 2019-10-22T05:27:32.053Z)
OS version: Windows_NT x64 10.0.18362

System Info
Item Value
CPUs Intel(R) Xeon(R) W-2133 CPU @ 3.60GHz (12 x 3600)
GPU Status 2d_canvas: enabled
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
metal: disabled_off
multiple_raster_threads: enabled_on
oop_rasterization: disabled_off
protected_video_decode: unavailable_off
rasterization: enabled
skia_renderer: disabled_off
surface_control: disabled_off
surface_synchronization: enabled_on
video_decode: enabled
viz_display_compositor: enabled_on
viz_hit_test_surface_layer: disabled_off
webgl: enabled
webgl2: enabled
Load (avg) undefined
Memory (System) 31.73GB (11.96GB free)
Process Argv
Screen Reader no
VM 0%
Extensions (2)
Extension Author (truncated) Version
vscode-typescript-tslint-plugin ms- 1.2.2
azurerm-vscode-tools msa 0.7.0

Metadata

Metadata

Assignees

Labels

bugIssue identified by VS Code Team member as probable bugdebugDebug viewlet, configurations, breakpoints, adapter issuesinsiders-releasedPatch has been released in VS Code InsidersverifiedVerification succeeded

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions