App base on electron13 (13.6.9-1) start failed on kde (5.24.2) wayland session

code --verbose --log=TRACE --enable-features=UseOzonePlatform --ozone-platform=wayland

Warning: 'enable-features' is not in the list of known options, but still passed to Electron/Chromium.
Warning: 'ozone-platform' is not in the list of known options, but still passed to Electron/Chromium.
[9539:0302/165141.918462:WARNING:wayland_drm.cc(68)] Failed to get drm magic
[9574:0302/165142.057884:ERROR:gpu_init.cc(440)] Passthrough is not supported, GL is egl
[9574:0302/165142.062651:ERROR:sandbox_linux.cc(374)] InitializeSandbox() called with multiple threads in process gpu-process.
[main 2022-03-02T08:51:42.100Z] [File Watcher (node.js)] Request to start watching: /home/user/.config/Code - OSS/User (excludes: <none>),/home/user/.config/Code - OSS/User/settings.json (excludes: <none>)
[main 2022-03-02T08:51:42.131Z] Starting VS Code
[main 2022-03-02T08:51:42.131Z] from: /usr/lib/code
[main 2022-03-02T08:51:42.131Z] args: {
  _: [],
  diff: false,
  add: false,
  goto: false,
  'new-window': false,
  'reuse-window': false,
  wait: false,
  help: false,
  'list-extensions': false,
  'show-versions': false,
  'pre-release': false,
  version: false,
  verbose: true,
  log: 'TRACE',
  status: false,
  'prof-startup': false,
  'no-cached-data': false,
  'prof-v8-extensions': false,
  'disable-extensions': false,
  'disable-gpu': false,
  'ms-enable-electron-run-as-node': false,
  telemetry: false,
  debugRenderer: false,
  logExtensionHostCommunication: false,
  'skip-release-notes': false,
  'skip-welcome': false,
  'disable-telemetry': false,
  'disable-updates': false,
  'disable-keytar': false,
  'disable-workspace-trust': false,
  'disable-crash-reporter': false,
  'skip-add-to-recently-opened': false,
  'unity-launch': false,
  'open-url': false,
  'file-write': false,
  'file-chmod': false,
  'driver-verbose': false,
  force: false,
  'do-not-sync': false,
  trace: false,
  'force-user-env': false,
  'force-disable-user-env': false,
  'open-devtools': false,
  __sandbox: false,
  'no-proxy-server': false,
  'no-sandbox': false,
  nolazy: false,
  'force-renderer-accessibility': false,
  'ignore-certificate-errors': false,
  'allow-insecure-localhost': false,
  logsPath: '/home/user/.config/Code - OSS/logs/20220302T165142'
}
[main 2022-03-02T08:51:42.136Z] Resolving machine identifier...
[main 2022-03-02T08:51:42.136Z] Resolved machine identifier: 51b8d65f0a7642d4dba860ff98764471d7c1bb49b6f7bd875bc29e12aeaf2963
[main 2022-03-02T08:51:42.136Z] Main->SharedProcess#connect
[main 2022-03-02T08:51:42.142Z] [File Watcher (node.js)] Started watching: '/home/user/.config/Code - OSS/User'
[main 2022-03-02T08:51:42.143Z] [File Watcher (node.js)] Started watching: '/home/user/.config/Code - OSS/User/settings.json'
[main 2022-03-02T08:51:42.148Z] StorageMainService: creating global storage
[main 2022-03-02T08:51:42.156Z] lifecycle (main): phase changed (value: 2)
[main 2022-03-02T08:51:42.156Z] windowsManager#open
[main 2022-03-02T08:51:42.157Z] windowsManager#open pathsToOpen [
  {
    workspace: { id: 'bee0e8e2bf8745d925d6efdd5da3ec21', uri: [d] },
    type: 2,
    exists: true
  }
]
[main 2022-03-02T08:51:42.158Z] windowsManager#doOpenFolderOrWorkspace {
  folderOrWorkspace: {
    workspace: { id: 'bee0e8e2bf8745d925d6efdd5da3ec21', uri: [d] },
    type: 2,
    exists: true
  },
  filesToOpen: undefined
}
[main 2022-03-02T08:51:42.159Z] IPC Object URL: Registered new channel vscode:01c00b94-cbbf-461f-a50e-cdea3f124e50.
[main 2022-03-02T08:51:42.160Z] window#validateWindowState: validating window state on 1 display(s) { mode: 0, x: 0, y: 0, width: 1024, height: 720 }
[main 2022-03-02T08:51:42.160Z] window#validateWindowState: 1 monitor working area { x: 0, y: 0, width: 1280, height: 720 }
[main 2022-03-02T08:51:42.160Z] window#ctor: using window state { mode: 0, x: 0, y: 0, width: 1024, height: 720 }
[9539:0302/165142.161744:WARNING:wayland_surface.cc(63)] Server doesn't support zwp_linux_explicit_synchronization_v1.
[9539:0302/165142.162471:ERROR:cursor_loader.cc(107)] Failed to load a platform cursor of type kNull
[main 2022-03-02T08:51:42.208Z] StorageMainService: creating workspace storage (bee0e8e2bf8745d925d6efdd5da3ec21)
[main 2022-03-02T08:51:42.209Z] windowsManager#open used window count 1 (workspacesToOpen: 0, foldersToOpen: 1, emptyToRestore: 0, emptyToOpen: 0)
[main 2022-03-02T08:51:42.210Z] lifecycle (main): phase changed (value: 3)
[main 2022-03-02T08:51:42.210Z] update#ctor - updates are disabled as there is no update URL
[main 2022-03-02T08:51:42.210Z] resolveShellEnv(): skipped (VSCODE_CLI is set)
[9539:0302/165142.279488:ERROR:platform_shared_memory_region_posix.cc(47)] Descriptor access mode (2) differs from expected (0)
Failed to generate minidump.

Could be related to this?

No, --no-sandbox argument does not help.

electron13 in archlinux has fixed this in sway compositor:
the bug id in archlinux is 73544

I cannot reproduce on KDE wayland. Can you try with --disable-gpu-sandbox parmeter as suggested here. If this works then you can copy /usr/share/applications/code-oss.desktop to ~/.local/share/applications and modify the “Exec” line accordingly. Make sure you reboot afterwards and then you should be able to launch code as usual from any application launcher.

mkdir -p "${XDG_DATA_HOME:-$HOME/.local/share}/applications"
cp -a "/usr/share/applications/code-oss.desktop" "${XDG_DATA_HOME:-$HOME/.local/share}/applications/code-oss.desktop"
sed -i -e 's,/usr/bin/code-oss --unity-launch %F,/usr/bin/code-oss --unity-launch --disable-gpu-sandbox %F,' "${XDG_DATA_HOME:-$HOME/.local/share}/applications/code-oss.desktop"
sed -i -e 's,/usr/bin/code-oss --new-window %F,/usr/bin/code-oss --new-window --disable-gpu-sandbox %F,' "${XDG_DATA_HOME:-$HOME/.local/share}/applications/code-oss.desktop"

–disable-gpu-sandbox does not help too. I run kwin_wayland with drm backend.

code --verbose --log=TRACE --enable-features=UseOzonePlatform --ozone-platform=wayland --disable-gpu-sandbox

Warning: 'enable-features' is not in the list of known options, but still passed to Electron/Chromium.
Warning: 'ozone-platform' is not in the list of known options, but still passed to Electron/Chromium.
Warning: 'disable-gpu-sandbox' is not in the list of known options, but still passed to Electron/Chromium.
[4084:0306/224024.279868:WARNING:wayland_drm.cc(68)] Failed to get drm magic
[main 2022-03-06T14:40:24.409Z] [File Watcher (node.js)] Request to start watching: /home/user/.config/Code - OSS/User (excludes: <none>),/home/user/.config/Code - OSS/User/settings.json (excludes: <none>)
[main 2022-03-06T14:40:24.427Z] Starting VS Code
[main 2022-03-06T14:40:24.428Z] from: /usr/lib/code
[main 2022-03-06T14:40:24.428Z] args: {
  _: [],
  diff: false,
  add: false,
  goto: false,
  'new-window': false,
  'reuse-window': false,
  wait: false,
  help: false,
  'list-extensions': false,
  'show-versions': false,
  'pre-release': false,
  version: false,
  verbose: true,
  log: 'TRACE',
  status: false,
  'prof-startup': false,
  'no-cached-data': false,
  'prof-v8-extensions': false,
  'disable-extensions': false,
  'disable-gpu': false,
  'ms-enable-electron-run-as-node': false,
  telemetry: false,
  debugRenderer: false,
  logExtensionHostCommunication: false,
  'skip-release-notes': false,
  'skip-welcome': false,
  'disable-telemetry': false,
  'disable-updates': false,
  'disable-keytar': false,
  'disable-workspace-trust': false,
  'disable-crash-reporter': false,
  'skip-add-to-recently-opened': false,
  'unity-launch': false,
  'open-url': false,
  'file-write': false,
  'file-chmod': false,
  'driver-verbose': false,
  force: false,
  'do-not-sync': false,
  trace: false,
  'force-user-env': false,
  'force-disable-user-env': false,
  'open-devtools': false,
  __sandbox: false,
  'no-proxy-server': false,
  'no-sandbox': false,
  nolazy: false,
  'force-renderer-accessibility': false,
  'ignore-certificate-errors': false,
  'allow-insecure-localhost': false,
  logsPath: '/home/user/.config/Code - OSS/logs/20220306T224024'
}
[main 2022-03-06T14:40:24.430Z] Resolving machine identifier...
[main 2022-03-06T14:40:24.430Z] Resolved machine identifier: 51b8d65f0a7642d4dba860ff98764471d7c1bb49b6f7bd875bc29e12aeaf2963
[main 2022-03-06T14:40:24.430Z] Main->SharedProcess#connect
[main 2022-03-06T14:40:24.434Z] [File Watcher (node.js)] Started watching: '/home/user/.config/Code - OSS/User'
[main 2022-03-06T14:40:24.435Z] [File Watcher (node.js)] Started watching: '/home/user/.config/Code - OSS/User/settings.json'
[main 2022-03-06T14:40:24.438Z] StorageMainService: creating global storage
[main 2022-03-06T14:40:24.442Z] lifecycle (main): phase changed (value: 2)
[main 2022-03-06T14:40:24.443Z] windowsManager#open
[4119:0306/224024.444394:ERROR:gpu_init.cc(440)] Passthrough is not supported, GL is egl
[main 2022-03-06T14:40:24.444Z] windowsManager#open pathsToOpen [
  {
    workspace: { id: 'd4cfd781067ebf1709dcd366a5cdb3b5', uri: [d] },
    type: 2,
    exists: true
  }
]
[main 2022-03-06T14:40:24.445Z] windowsManager#doOpenFolderOrWorkspace {
  folderOrWorkspace: {
    workspace: { id: 'd4cfd781067ebf1709dcd366a5cdb3b5', uri: [d] },
    type: 2,
    exists: true
  },
  filesToOpen: undefined
}
[main 2022-03-06T14:40:24.446Z] IPC Object URL: Registered new channel vscode:00da350b-8cde-47a7-8ba4-260f2220b2ac.
[main 2022-03-06T14:40:24.447Z] window#validateWindowState: validating window state on 1 display(s) { mode: 0, x: 0, y: 0, width: 1024, height: 768 }
[main 2022-03-06T14:40:24.447Z] window#validateWindowState: 1 monitor working area { x: 0, y: 0, width: 1280, height: 720 }
[main 2022-03-06T14:40:24.447Z] window#ctor: using window state { mode: 0, x: 0, y: 0, width: 1024, height: 720 }
[4084:0306/224024.448129:WARNING:wayland_surface.cc(63)] Server doesn't support zwp_linux_explicit_synchronization_v1.
[4084:0306/224024.448660:ERROR:cursor_loader.cc(107)] Failed to load a platform cursor of type kNull
[4119:0306/224024.451627:ERROR:sandbox_linux.cc(374)] InitializeSandbox() called with multiple threads in process gpu-process.
[main 2022-03-06T14:40:24.488Z] StorageMainService: creating workspace storage (d4cfd781067ebf1709dcd366a5cdb3b5)
[main 2022-03-06T14:40:24.489Z] windowsManager#open used window count 1 (workspacesToOpen: 0, foldersToOpen: 1, emptyToRestore: 0, emptyToOpen: 0)
[main 2022-03-06T14:40:24.489Z] lifecycle (main): phase changed (value: 3)
[main 2022-03-06T14:40:24.489Z] update#ctor - updates are disabled as there is no update URL
[main 2022-03-06T14:40:24.489Z] resolveShellEnv(): skipped (VSCODE_CLI is set)
[4084:0306/224024.563044:ERROR:platform_shared_memory_region_posix.cc(47)] Descriptor access mode (2) differs from expected (0)
Failed to generate minidump.

Please try for better readability and format your posts accordingly as you already did in the initial post of this thread: