-
Notifications
You must be signed in to change notification settings - Fork 338
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
VSCode API in extension host uses "Null extension" #4658
Comments
An old vscode issue microsoft/vscode#67326 suggests that this could indicate the extension isn't registered as "requiring vscode". Maybe this is because |
This change seems to fix the issue, at least for the diff --git a/packages/core/package.json b/packages/core/package.json
index cc70f43be69c..6a5066bb21a0 100644
--- a/packages/core/package.json
+++ b/packages/core/package.json
@@ -2,32 +2,6 @@
"name": "aws-core-vscode",
"description": "Core library used AWS IDE extensions for VSCode.",
"version": "1.0.0",
- "extensionKind": [
- "workspace"
- ],
- "publisher": "amazonwebservices",
- "license": "Apache-2.0",
- "engines": {
- "npm": "^10.1.0",
- "vscode": "^1.68.0"
- },
- "activationEvents": [
- "onStartupFinished",
- "onUri",
- "onDebugResolve:aws-sam",
- "onView:aws.codeWhisperer.securityPanel",
- "onDebugInitialConfigurations",
- "onLanguage:javascript",
- "onLanguage:java",
- "onLanguage:python",
- "onLanguage:csharp",
- "onLanguage:yaml",
- "onFileSystem:s3",
- "onFileSystem:s3-readonly",
- "onCommand:aws.codeWhisperer.accept"
- ],
- "main": "./dist/src/extension.js",
- "browser": "./dist/src/extensionWeb",
"exports": {
".": "./dist/src/index.js",
"./web": "./dist/src/indexWeb.js", |
Fixes: aws#4658 Signed-off-by: Nikolas Komonen <nkomonen@amazon.com>
Fixes: #4658 Signed-off-by: Nikolas Komonen <nkomonen@amazon.com>
Problem
When debugging the extension in the extension host several VSCode API's are falling back to using the default built in "Null extension", rather than registering the API for the toolkit extension. This has been observed in the latest commit
30507f96f57de5fb579d05e2238dd08a5af58da0
but the most likely root cause is the major refactoring to support multiple packages in the repository.Steps to reproduce the issue
npm install
Extension (toolkit)
Toggle theRun the Command Palette command:editor.inlineSuggest.enabled
settingAWS: Edit Credentials
Alternatively,
npm install
Extension (toolkit)
https://github.com/aws/aws-toolkit-vscode/blob/master/packages/core/src/codecatalyst/uriHandlers.ts#L49
vscode://amazonwebservices.aws-toolkit-vscode/connect/codecatalyst?spaceName=foo&projectName=foo&devEnvironmentId=123123123123
in the browserOther things to note
vscode.window.registerUriHandler
if you set a breakpoint in the debugger and then step in you eventually see that it's registering with the "Null extension" but you would expect the uri to register with the "aws toolkit extension"vscode.window.showInformationWindow
inside oftoolkit/src/main.ts
then it shows that everything is registered withAWS Toolkit - Amazon Q, CodeWhisperer, and more
vscode.window.showInformationWindow
inside ofcore/src/extension.ts
then it shows that everything is registered with `Null extension description'Expected behavior
Extension host and the compiled vsix behaviour should be the same (showInformationMessage should show
AWS Toolkit - Amazon Q, CodeWhisperer, and more
, uri breakpoint handlers should be hit, etc)System details (run the
AWS: About Toolkit
command)The text was updated successfully, but these errors were encountered: