Repository: vscode
Issue: Terminal fails to open after setting terminal.integrated.cwd in multi-root workspace
Labels: bug,terminal-process

Type: <b>Bug</b>

Steps to reproduce:

* Open a multi-root workspace.
* Set `terminal.integrated.cwd` to one of the root directories/folders of the workspace. 
* Attempt to open a terminal.
* Expected: the new terminal opens in that directory, thus avoiding being asked "Select current working directory for new terminal" every time you open a terminal in a multi-root workspace.
* Actual: nothing. No terminal opens. The following line appears in `terminal.log`: `[warning] The terminal process failed to launch: Starting directory (cwd) "<the directory to which I set terminal.integrated.cwd which *does* exist>" does not exist. []`. The log is obtained with the command "Develop: open log file"/Terminal.

Is there some other way to select the default folder to use for the integrated terminal in a multi-root workspace?

VS Code version: Code 1.86.2 (903b1e9d8990623e3d7da1df3d33db3e42d80eda, 2024-02-13T19:40:56.878Z)
OS version: Windows_NT x64 10.0.22631
Modes:
Remote OS version: Linux x64 5.15.0-88-generic

<details>
<summary>System Info</summary>

|Item|Value|
|---|---|
|CPUs|12th Gen Intel(R) Core(TM) i9-12900KF (24 x 3187)|
|GPU Status|2d_canvas: enabled<br>canvas_oop_rasterization: enabled_on<br>direct_rendering_display_compositor: disabled_off_ok<br>gpu_compositing: enabled<br>multiple_raster_threads: enabled_on<br>opengl: enabled_on<br>rasterization: enabled<br>raw_draw: disabled_off_ok<br>skia_graphite: disabled_off<br>video_decode: enabled<br>video_encode: enabled<br>vulkan: disabled_off<br>webgl: enabled<br>webgl2: enabled<br>webgpu: enabled|
|Load (avg)|undefined|
|Memory (System)|63.80GB (48.57GB free)|
|Process Argv||
|Screen Reader|no|
|VM|0%|

|Item|Value|
|---|---|
|Remote|SSH: ubuntu3|
|OS|Linux x64 5.15.0-88-generic|
|CPUs|Intel(R) Core(TM) i5-8400 CPU @ 2.80GHz (2 x 2808)|
|Memory (System)|3.28GB (1.75GB free)|
|VM|0%|
</details><details><summary>Extensions (75)</summary>

Extension|Author (truncated)|Version
---|---|---
Bookmarks|ale|13.4.2
clipboard-manager|Edg|1.5.0
vscode-great-icons|emm|2.1.102
vscode-firefox-debug|fir|2.9.10
vscode-apache|mrm|1.2.0
jupyter-keymap|ms-|1.1.2
remote-containers|ms-|0.338.1
remote-ssh|ms-|0.108.0
remote-ssh-edit|ms-|0.86.0
remote-wsl|ms-|0.86.0
vscode-remote-extensionpack|ms-|0.25.0
remote-explorer|ms-|0.4.1
remote-server|ms-|1.5.0
php-docblocker|nei|2.7.0
back-n-forth|nic|3.1.1
material-icon-theme|PKi|4.34.0
json-script-tag|sis|0.3.2
rewrap|stk|1.16.3
errorlens|use|3.16.0
vscode-todo-highlight|way|1.0.5
JavaScriptSnippets|xab|1.8.0
material-theme|zhu|3.16.2
Bookmarks|ale|13.4.2
webbookmarks|alu|1.2.5
laravel-extra-intellisense|ami|0.6.4
laravel-blade-vscode|ami|2.0.4
markdown-emoji|bie|0.3.0
vscode-intelephense-client|bme|1.10.2
vscode-tailwindcss|bra|0.10.5
insert-unicode|bru|0.15.1
laravel-goto-view|cod|1.3.11
vscode-eslint|dba|2.4.4
xml|Dot|2.5.1
vscode-html-css|ecm|2.0.9
vscode-command-runner|edo|0.0.124
prettier-vscode|esb|10.1.0
vscode-terminals|fab|1.15.0
dotnet-test-explorer|for|0.7.8
vscode-jasmine-test-adapter|hbe|1.8.2
vscode-test-explorer|hbe|2.21.1
vscode-favorites|how|1.11.0
browsersync|jer|2.2.2
vscode-gist|ken|3.0.3
calculator|lix|0.1.1
git-graph|mhu|1.30.0
vscode-scss|mrm|0.10.0
csharp|ms-|2.18.16
vscode-dotnet-runtime|ms-|2.0.1
debugpy|ms-|2024.0.0
isort|ms-|2023.10.1
python|ms-|2024.0.1
vscode-pylance|ms-|2024.2.2
jupyter|ms-|2024.1.1
jupyter-keymap|ms-|1.1.2
jupyter-renderers|ms-|1.0.17
vscode-jupyter-cell-tags|ms-|0.1.8
vscode-jupyter-slideshow|ms-|0.1.5
live-server|ms-|0.4.13
test-adapter-converter|ms-|0.1.9
sqltools|mtx|0.28.1
php-docblocker|nei|2.7.0
vscode-data-preview|Ran|2.3.0
vscode-phpunit|rec|3.2.2
vscode-sort-json|ric|1.20.0
LiveServer|rit|5.7.9
vscode-coverage-gutters|rya|2.11.1
trailing-spaces|sha|0.4.1
vscode-blade-formatter|shu|0.24.1
vscode-scss-formatter|sib|3.0.0
rewrap|stk|1.16.3
code-spell-checker|str|3.0.1
vscode-workspace-explorer|tom|1.5.0
errorlens|use|3.16.0
php-debug|xde|1.34.0
markdown-all-in-one|yzh|3.6.2


</details>
<!-- generated by issue reporter -->