question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Calling a Native Node.js Add-On API In an Extension Launches New Dock Icon for Extension Host Process in macOS

See original GitHub issue

Issue Type: Bug

I’m working on an extension for VS Code and have found that in 1.63 when I launch the debugger or issue a command from the Command Palette, a new VS Code icon appears in the macOS 10.14.6 Dock. It bounces for quite a while and only ever shows “Force Quit” when right-clicked.

image

If you do “Force Quit” the icon, an error message pops up in the VS Code Window that issued the command that reads “Extension host terminated unexpectedly.” It provides two options:

  1. Open Developer Tools
  2. Restart Extension Host

Restarting the Extension Host works just fine. To be clear, the extension appears to work as expected as well (until the new Dock icon is force-quit, of course).

I just did a bunch of work on the extension build process for the extension I’m working on, so I thought the issue was on my end. However, I tested the same build of my extension in VS Code 1.62 and it did not exhibit this odd functionality. I also tested the older version of the extension I’m working on and it caused the same issue. Seems to repro 100% of the time for me.

I searched around the issues but wasn’t able to find anything. Any insights as to what’s going on (or if this is simply just a VS Code bug) would be greatly appreciated.

VS Code version: Code 1.63.0 (7db1a2b88f7557e0a43fec75b6ba7e50b3e9f77e, 2021-12-07T05:15:48.091Z) OS version: Darwin x64 18.7.0 Restricted Mode: No Remote OS version: Linux x64 5.10.47-linuxkit Remote OS version: Linux x64 5.10.47-linuxkit

Extensions (5)
Extension Author (truncated) Version
extendscript-debug Ado 2.0.0-beta0
githistory don 0.6.19
vscode-diff fab 1.4.2
jupyter-renderers ms- 1.0.4
remote-containers ms- 0.209.3
A/B Experiments
vsliv368:30146709
vsreu685:30147344
python383cf:30185419
vspor879:30202332
vspor708:30202333
vspor363:30204092
vstes627:30244334
pythontb:30283811
pythonvspyt551:30345470
pythonptprofiler:30281270
vshan820:30294714
vstes263:30335439
vscoreces:30384385
pythondataviewer:30285071
vscod805:30301674
pythonvspyt200:30340761
binariesv615:30325510
bridge0708:30335490
bridge0723:30353136
pythonrunftest32:30373476
pythonf5test824:30373475
javagetstartedt:30391933
pythonvspyt187:30373474
vsaa593cf:30376535
pythonvs932cf:30408637
vscop804:30404766
vscop940:30404999
vsrem710cf:30405999
vscexrecpromp3t3:30407764

Issue Analytics

  • State:open
  • Created 2 years ago
  • Reactions:20
  • Comments:25 (3 by maintainers)

github_iconTop GitHub Comments

20reactions
jaydenwindlecommented, Dec 28, 2021

After running into this issue, I was able to determine which extension was causing the extra dock icons by doing the following:

  1. Disable all extensions and reload VSCode
  2. Enable extensions one-by-one, reloading if required
  3. Immediately after enabling the extension causing this issue, the extra dock icons will appear

In my case, Spell Right was the culprit. After uninstalling the extension and reloading VSCode, the extra dock icons were gone.

13reactions
philsherrycommented, Dec 15, 2021

I’ve currently got 5 VS Code projects open and this is what my Dock looks like. Full-length image to show the context menu, but also the dividing line in the Dock—of which they’re on the running apps side, not the recently run side (as I saw mentioned elsewhere in some closed Issues).

dock-github

Right-clicking any of those shows “Application not responding” between Options and the list of recent Project folders. I do not get this behaviour with the latest version of Insiders.

I’m running macOS 12.1 (21C52) and these are my VS Code details:

Version: 1.63.1
Commit: fe719cd3e5825bf14e14182fddeb88ee8daf044f
Date: 2021-12-14T02:13:13.580Z (1 day ago)
Electron: 13.5.2
Chromium: 91.0.4472.164
Node.js: 14.16.0
V8: 9.1.269.39-electron.0
OS: Darwin x64 21.2.0

This is causing mayhem in my neurodivergent brain. 🔥🧠🔥

Read more comments on GitHub >

github_iconTop Results From Across the Web

Native extensions for NodeJS
This NodeJS module provides us with a C++ implementation of N-API and allows us to use the language advantages. First steps in the...
Read more >
All the Electron Docs! | Electron
Electron is an open source library developed by GitHub for building cross-platform desktop applications with HTML, CSS, and JavaScript. Electron accomplishes ...
Read more >
Asynchronous C++ Addon for Node.js with N-API ... - CodeMerx
Node. js addons are distributed like every other NPM package. On install node-gyp will be called and the native C/C++ code will be...
Read more >
Accelerator - Electron - W3cubDocs
Emitted when the user clicks the native macOS new tab button. ... In Electron there are two sets of APIs: Node APIs provided...
Read more >
Making plugins - Godot Docs
A plugin is a great way to extend the editor with useful tools. It can be made entirely with GDScript and standard scenes,...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found