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.

Extension being triggered for a language that isn't specified as an activation event

See original GitHub issue

Type: Bug

  1. Have the Python extension, and no others, enabled
  2. Create a new directory, and an empty .yml file within it
  3. Open that file

Expected behavior: The file opens. No extensions activate, as none are installed that have anything to do with arbitrary YAML.

Actual behavior: The Python extension attempts to activate, then crashes with this error message in the console:

Activating extension 'ms-python.python' failed: Extension 'ms-python.python' CANNOT use API proposal: telemetryLogger.
Its package.json#enabledApiProposals-property declares:  but NOT telemetryLogger.
 The missing proposal MUST be added and you must start in extension development mode or use the following command line switch: --enable-proposed-api ms-python.python

It’s not necessarily an issue, but it is incredibly annoying to open my CI config, see an error popup, think something has actually gone wrong, and then discover that Python is just choking – which is irrelevant because this project isn’t even using Python! Plus, it leaves a little spinning loader and pointless text saying the Python extension is loading, forever, because

(The details are from when I first noticed this bug; I disabled all other non-default extensions and tried with fresh YAML in empty directories before submitting this bug report.)

Extension version: 2022.20.0 VS Code version: Code - OSS 1.74.0 (5235c6bb189b60b01b1f49062f4ffa42384f8c91, 2022-12-07T23:49:16.764Z) OS version: Linux x64 6.0.8-arch1-1 Modes: Sandboxed: No

System Info
Item Value
CPUs AMD Ryzen 9 3950X 16-Core Processor (32 x 3205)
GPU Status 2d_canvas: enabled
canvas_oop_rasterization: disabled_off
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
skia_renderer: enabled_on
video_decode: disabled_software
video_encode: disabled_software
vulkan: disabled_off
webgl: enabled
webgl2: enabled
webgpu: disabled_off
Load (avg) 2, 2, 2
Memory (System) 15.55GB (7.80GB free)
Process Argv –unity-launch
Screen Reader no
VM 0%
DESKTOP_SESSION i3
XDG_CURRENT_DESKTOP i3
XDG_SESSION_DESKTOP i3
XDG_SESSION_TYPE x11

Issue Analytics

  • State:open
  • Created 9 months ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
brettcannoncommented, Dec 14, 2022

I’m going to transfer this over to the vscode issue tracker to see if they have any idea of what might be going on.

0reactions
nic-hartleycommented, Dec 14, 2022

Just updated to the latest version and yes, the issue persists, still with the same onLanguage:yaml activation event.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Activation Events | Visual Studio Code Extension API
This activation event is emitted and interested extensions will be activated whenever a file that resolves to a certain language gets opened.
Read more >
VSCode extension activation event onCreate file
If you are only interested in files of a specific language, use the onLanguage: activation event. This will be fired when a new...
Read more >
Sourcegraph extension activation
Sourcegraph extension activation. Sourcegraph selectively activates each extension based on the activationEvents array in its package.json .
Read more >
Configure your Outlook add-in for event-based activation
To enable event-based activation of your add-in, you must configure the Runtimes element and LaunchEvent extension point in the ...
Read more >
Simple Triggers | Apps Script - Google Developers
Triggers let Apps Script run a function automatically when a certain event, ... than simple triggers but must be activated before use.
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