Describe the bug
Command "chrome.exe --headless --user-data-dir=${USER_DATA_DIR}" does NOT work if USER_DATA_DIR comes as or with any parent as directory junction, which may fail Microsoft Edge DevTools.
To Reproduce
Steps to reproduce the behavior:
- Enable portable mode of VS Code by create folder "data" as directory junction rather than real folder.
- Open a folder with html file inside, for example a local copy of folder "demo-to-do" from Microsoft Edge Demos.
- Try to start Edge DevTools by right-clicking an HTML file, for example file index.html in folder "demo-to-do".

- See what pop up are NOT Edge DevTools tab and Edge DevTools: Browser tab,

BUT error dialog box.

Log File
Not available.
VS Code Version: 1.76.2
Additional context
- Generating launch.json and invoking "Launch Edge Headless and attach DevTools" results in same error.
- Invoking "Launching Edge and attach DevTools" workarounds this error.
- It is reasonable to conclude that argument --headless do matters.
- Switching to "pwa-chrome" in launch.json results in same as "pwa-msedge".
- USER_DATA_DIR with directory junction fails command "chrome.exe --headless --user-data-dir=${USER_DATA_DIR}".
- USER_DATA_DIR with directory junction does NOT fail command "chrome.exe --user-data-dir=${USER_DATA_DIR}".
- USER_DATA_DIR with directory junction does NOT fail command "chrome.exe --headless --no-sandbox --user-data-dir=${USER_DATA_DIR}".
- It is reasonable to speculate that there is some conflict among feature Headless and feature Sandbox and option USER_DATA_DIR with directory junction in Chromium and derived Edge and Chrome.
- I have tried to use fs.realpathSync() to purify resolvedDataDir in launchBrowser() in src/targets/browser/browserLauncher.ts, and prevented Edge DevTools from reproducing that unexpected behavior on OS Windows.
- Let me know if there is some introduced impact not taken into my account, for example some unanticipated side effect on OS other than Windows.
Describe the bug
Command "chrome.exe --headless --user-data-dir=${USER_DATA_DIR}" does NOT work if USER_DATA_DIR comes as or with any parent as directory junction, which may fail Microsoft Edge DevTools.
To Reproduce
Steps to reproduce the behavior:
BUT error dialog box.
Log File
Not available.
VS Code Version: 1.76.2
Additional context