vscode: __vsc_update_env:7: unknown condition: -v
Type: Bug
After vscode is updated to version 1.100.0, when I use remote ssh to connect to a machine and open the integrated terminal zsh, "__vsc_update_env:7: unknown condition: -v " will repeatly appear when I input a terminal command.
VS Code version: Code 1.100.0 (19e0f9e681ecb8e5c09d8784acaa601316ca4571, 2025-05-07T12:48:53.763Z) OS version: Windows_NT x64 10.0.19045 Modes: Remote OS version: Linux x64 3.10.0-1062.el7.x86_64
System Info
| Item | Value |
|---|---|
| CPUs | Intel® Core™ i7-10700 CPU @ 2.90GHz (16 x 2904) |
| GPU Status | 2d_canvas: enabled canvas_oop_rasterization: enabled_on direct_rendering_display_compositor: disabled_off_ok gpu_compositing: enabled multiple_raster_threads: enabled_on opengl: enabled_on rasterization: enabled raw_draw: disabled_off_ok skia_graphite: disabled_off video_decode: enabled video_encode: enabled vulkan: disabled_off webgl: enabled webgl2: enabled webgpu: enabled webnn: disabled_off |
| Load (avg) | undefined |
| Memory (System) | 31.72GB (12.92GB free) |
| Process Argv | –crash-reporter-id b9e57052-07cf-451c-852a-bd99546158b4 |
| Screen Reader | yes |
| VM | 29% |
| Item | Value |
|---|---|
| Remote | SSH: 192.168.2.91 |
| OS | Linux x64 3.10.0-1062.el7.x86_64 |
| CPUs | Intel® Xeon® CPU E5-2643 v4 @ 3.40GHz (24 x 3652) |
| Memory (System) | 62.67GB (35.48GB free) |
| VM | 0% |
Extensions (49)
| Extension | Author (truncated) | Version |
|---|---|---|
| Doxygen | bbe | 1.0.0 |
| continue | Con | 1.0.8 |
| tcl-language-support | go2 | 0.1.2 |
| systemverilog-1800-2012 | gve | 1.0.27 |
| better-cpp-syntax | jef | 1.27.1 |
| mips | kda | 0.1.3 |
| restructuredtext | lex | 190.4.7 |
| remote-ssh | ms- | 0.121.2025050818 |
| remote-ssh-edit | ms- | 0.87.0 |
| remote-wsl | ms- | 0.99.0 |
| vscode-remote-extensionpack | ms- | 0.26.0 |
| remote-explorer | ms- | 0.4.3 |
| remote-server | ms- | 1.5.2 |
| material-icon-theme | PKi | 5.22.0 |
| cdl | qua | 0.0.1 |
| rewrap | stk | 1.16.3 |
| tom | 1.2.2 | |
| vscode-icons | vsc | 12.12.0 |
| vim | vsc | 1.29.0 |
| spice | xua | 0.1.0 |
| increment-selection | alb | 0.2.0 |
| tongyi-lingma | Ali | 2.5.2 |
| dvt | ami | 25.1.8 |
| waveform-render | bmp | 0.27.0 |
| path-intellisense | chr | 2.10.0 |
| doxdocgen | csc | 1.4.0 |
| githistory | don | 0.6.20 |
| copilot | Git | 1.317.0 |
| copilot-chat | Git | 0.27.0 |
| systemverilog-1800-2012 | gve | 1.0.27 |
| skill | her | 0.10.0 |
| align-by-regex | jan | 1.0.4 |
| marscode-extension | Mar | 1.2.4 |
| rainbow-csv | mec | 3.17.0 |
| git-graph | mhu | 1.30.0 |
| debugpy | ms- | 2024.8.0 |
| python | ms- | 2024.12.1 |
| vscode-pylance | ms- | 2024.7.1 |
| cmake-tools | ms- | 1.20.52 |
| cpptools | ms- | 1.25.3 |
| cpptools-extension-pack | ms- | 1.3.1 |
| hexeditor | ms- | 1.11.1 |
| makefile-tools | ms- | 0.12.17 |
| open-html-in-browser | pea | 2.1.10 |
| upf | PYG | 0.0.7 |
| claude-dev | sao | 3.14.1 |
| markdown-preview-enhanced | shd | 0.8.18 |
| cmake | twx | 0.0.17 |
| vscode-counter | uct | 3.6.1 |
(2 theme extensions excluded)
A/B Experiments
vsliv368:30146709
vspor879:30202332
vspor708:30202333
vspor363:30204092
vswsl492:30256859
vscod805cf:30301675
binariesv615:30325510
c4g48928:30535728
azure-dev_surveyone:30548225
a9j8j154:30646983
962ge761:30959799
2e7ec940:31000449
pythontbext0:30879054
cppperfnew:31000557
dwnewjupytercf:31046870
pythonrstrctxt:31112756
nativeloc2:31192216
5fd0e150:31155592
dwcopilot:31170013
6074i472:31201624
dwoutputs:31242946
customenabled:31248079
hdaa2157:31222309
copilot_t_ci:31222730
e5gg6876:31282496
pythoneinst12:31285622
bgtreat:31268568
4gafe986:31271826
31787653:31262186
3e8i5726:31271747
7bh79656:31259953
996jf627:31283433
pythonrdcb7cf:31303019
usemplatestapi:31297334
7bj51361:31289155
747dc170:31275177
aj496949:31278748
aj953862:31281341
generatesymbolt:31295002
convertfstringf:31295003
gendocf:31295004
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Comments: 20 (10 by maintainers)
Hello, zsh version 5 seems to be impacted too (on RHEL7):
@game1991 Yeah, the PR is here: https://github.com/microsoft/vscode/pull/252227 Will post again once the PR is merged so folks can try on VS Code - Insiders 😃
Looks good on both RHEL7 and centos7, I tested also on RHEL8 with a more recent version of zsh and the syntax is well interpreted by the shell in all the cases.
Again, thanks for your quick and efficient support!
@anthonykim1 thanks for your quick reply Seems the syntax used by the fix is not supported by zsh 5.0.2 :
But works for zsh 5.5.1 :
I have no choice to use RHEL7 with old zsh (big firm with heavy process and other stuff to migrate)
@GhislainC does
[[ -n "$key" && -n "${(P)key:-}" ]]work for you?Let’s use compatible syntax
@anthonykim1 it looks like
-vdoesn’t exist in somezshversions. It looks like a way to do this that would work for all versions is parameter expansion.if [[ ${(P)var+_} ]]; then