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

Code OSS cannot activate extension after update to 0.5.4 #59

Closed
RB-Lab opened this issue Dec 8, 2021 · 9 comments
Closed

Code OSS cannot activate extension after update to 0.5.4 #59

RB-Lab opened this issue Dec 8, 2021 · 9 comments

Comments

@RB-Lab
Copy link

RB-Lab commented Dec 8, 2021

Hello! First of all, this is really must have extension, thanks for creating it!

After update to version 0.5.4 the extension just stops working. After some couple of times reinstalling extension, I've notice the tab "Runtime Status", and on it it was said "Not yet activated". After quite some more time, I've found the "Log (Extension Host)" sections in logs panel and there was error:

[2021-12-08 12:31:54.295] [exthost] [error] Activating extension meganrogge.template-string-converter failed due to an error:
[2021-12-08 12:31:54.295] [exthost] [error] Error: Cannot find module '/home/user/.vscode-oss/extensions/meganrogge.template-string-converter-0.5.4/out/extension.js'

I went in the extension folder and found that in packge.json it is said: "main": "./out/extension.js". However there is no folder named out. But there is a file, named launch.json and in it there is a string:

"outFiles": ["${workspaceFolder}/dist/web/**/*.js"],

So, I've just copied all contend contend of dir/web into newly created out directory and everything looks to be working now.

I'm not familiar with Code extension publishing process, but it looks like something went wrong somewhere in it. Maybe it is due to my Code version, which is 1.62.0, or maybe it somehow related to the fact that in Arch's Linux Code uses different marketplace: Open VSX Registry.

@meganrogge
Copy link
Owner

Hey thanks so much for this report and info. Can you try updating to version 0.5.5? It's working for me in that version.

@meganrogge
Copy link
Owner

recording - 2021-12-08T085109 400

@RB-Lab
Copy link
Author

RB-Lab commented Dec 8, 2021

Emm.. is it available? In my repo it seems that 0.5.4 is the latest version:
image
And here on GitHub it seems to be as well.

@meganrogge
Copy link
Owner

it says version 0.5.5 is available in the marketplace https://marketplace.visualstudio.com/items?itemName=meganrogge.template-string-converter

@meganrogge
Copy link
Owner

also just tried rolling back to 0.5.4 and wasn't seeing the problem you describe there either.

@RB-Lab
Copy link
Author

RB-Lab commented Dec 9, 2021

Hm. Yeah, just downloaded 0.5.4 from VisualStudio Marketplace and there out folder is in place. Seem to be OpenVSX problem.

@RB-Lab
Copy link
Author

RB-Lab commented Dec 9, 2021

Ahh, damn, it's not even you who published the extension there!
image
Ok. I'll address this issue to open-vsx than.

@filiptronicek
Copy link

It looks like the out/ directory gets no longer generated, webpack outputs its results to dist/.

This is the result after packaging with vsce:
image

@meganrogge it looks like the wrong paths are here, or am I missing something?

"main": "./out/extension.js",
"publisher": "meganrogge",
"browser": "./out/extension.js",

@meganrogge
Copy link
Owner

meganrogge commented Dec 13, 2021

I made this web-enabled, which is why there is that browser entry there.

Replace the scripts in the package.json with:

"scripts": {
    "vscode:prepublish": "npm run compile",
    "compile": "tsc -p ./",
    "watch": "tsc -watch -p ./",
    "package-web": "eslint . --ext .ts,.tsx"
  },

it will work

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

3 participants