Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extension not being activated #413

Open
YusufSuleman opened this issue May 3, 2023 · 14 comments
Open

Extension not being activated #413

YusufSuleman opened this issue May 3, 2023 · 14 comments

Comments

@YusufSuleman
Copy link

Hello, I am making an extension, if I run it, the extension doesn't even get loaded. It doesn't say that the extension is even activated, in the debug console. I have the default code generated by making a new typescript extension, I am using Arch Linux which was updated a few days ago.

@sonicwang1989
Copy link

sonicwang1989 commented May 8, 2023

@YusufSuleman
modify activationEvents in package.json like this:
"activationEvents": [
"*"
],

@YusufSuleman
Copy link
Author

@sonicwang1989 Still not working, nothing changed

@kexposito
Copy link

@YusufSuleman, I had the same issue, just updated visual code and all it's working fine now 🎉

@Kadajett
Copy link

Same issue here. Gonna try to update?

@mikesmullin
Copy link

Yes I found under Help menu there was an option to restart to apply pending update. Then it worked.
I wonder if the project triggered vscode to recognize it had some new dependency, or if its just been that long for me?

@debemdeboas
Copy link

I'm having the same issue. Tried with JS and TS, no dice. I'm using WSL2, if that makes any difference. The extension doesn't seem to be loaded at all.

@kexposito
Copy link

Try using this engine:

  "engines": {
    "vscode": "^1.78.0"
  }

@debemdeboas
Copy link

Try using this engine:

  "engines": {
    "vscode": "^1.78.0"
  }

This worked! Thank you! Any idea as to a more permanent fix?

@kexposito
Copy link

Try using this engine:

  "engines": {
    "vscode": "^1.78.0"
  }

This worked! Thank you! Any idea as to a more permanent fix?

I have no clue about that :/ I realize that the issue was that version. So I tried change on my addon in it and it worked. Really happy that these also help you

@Aoko-Blue
Copy link

@YusufSuleman modify activationEvents in package.json like this: "activationEvents": [ "*" ],

Thank you for your method. It does work, but I would like to know why doing so can solve the problem?

@BestBugMaker
Copy link

Try using this engine:

  "engines": {
    "vscode": "^1.78.0"
  }

Can u tell me how to add this config?

@jtaavola
Copy link

Try using this engine:

  "engines": {
    "vscode": "^1.78.0"
  }

Can u tell me how to add this config?

It's in the package.json. The generator will specify latest version of VSCode, so if you're not up to date the extension won't be activated. You can either chance engines.vscode to the VSCode version you are on, or update your VSCode.

@Narayanbhat166
Copy link

Hey, the issue still seems to persist. However when i changed the engine to the above mentioned one ^1.78.0 it seems to work. Any idea why this is happening?

@jtaavola
Copy link

Hey, the issue still seems to persist. However when i changed the engine to the above mentioned one ^1.78.0 it seems to work. Any idea why this is happening?

engines.vscode indicates the version of vscode that your extension works on. The generator defaults to the latest version of vscode I believe.

https://docs.npmjs.com/cli/v10/configuring-npm/package-json#engines

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

10 participants