Skip to content

UI cannot copy a launch configuration into the workspace launch.json #245990

Closed
@eliericha

Description

@eliericha

Does this issue occur when all extensions are disabled?: Yes

  • VS Code Version: 1.99.0 (Universal)
  • OS Version: macOS 14.6.1

Steps to Reproduce:

  1. Start VS Code with --disable-extensions --user-data-dir $PWD/tmp-user-data-dir ws/ where tmp-user-data-dir and ws are initially empty
  2. Trigger the command Debug: Select and Start Debugging
  3. Select Node.js ...
  4. Click the gear icon on the right-side of the first listed item
  5. A .vscode/launch.json is created and opened in the editor, but the launch configuration is not added
  6. The Window output channel shows these errors (I repeated the action 3 times)
2025-04-08 15:31:35.844 [error] [Window] Cannot add property configurations, object is not extensible: TypeError: Cannot add property configurations, object is not extensible
    at frt.writeConfiguration (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:2241:264)
    at Wse.value (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:2240:15396)
2025-04-08 15:33:09.659 [error] [Window] Cannot assign to read only property 'configurations' of object '#<Object>': TypeError: Cannot assign to read only property 'configurations' of object '#<Object>'
    at frt.writeConfiguration (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:2241:264)
    at Wse.value (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:2240:15396)
2025-04-08 15:37:27.480 [error] [Window] Cannot assign to read only property 'configurations' of object '#<Object>': TypeError: Cannot assign to read only property 'configurations' of object '#<Object>'
    at frt.writeConfiguration (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:2241:264)
    at Wse.value (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:2240:15396)
  1. Using the same gear button on the second item of the list opens the User settings.json but the launch configuration is not added. The following error appears in the Window output channel:
025-04-08 15:50:39.674 [error] [Window] d.writeConfiguration is not a function: TypeError: d.writeConfiguration is not a function
    at Wse.value (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:2240:15396)

I hope this helps. Thanks!

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