-
Notifications
You must be signed in to change notification settings - Fork 29
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
The 'AWSToolkitPackage' package did not load correctly - CompositionFailedException: Expected 1 export(s) with contract name IToolkitContextProvider #441
Comments
I also have this issue. I believe I was using the most recent toolkit version prior to it breaking today, but I'm not completely sure. I've definitely updated it within the last few months. Windows 11 Pro 23H2 22631.3810 Initially the AWS Explorer tab was simply empty, but it now doesn't appear at all. The old version of the extension isn't visible anywhere I'm able to find in the Visual Studio UI, and the "AWS Toolkit with Amazon Q" appears as an installable extension (but doesn't install successfully.) Restarting Visual Studio does not solve the issue, nor does restarting my computer. The current extension version (1.54.0.0, "AWS Toolkit with Amazon Q") does seem to exist in |
I am also having this issue, If I try and use "AWS Toolkit with Amazon Q" version It doesn't allow me to install. with the "This extension is already installed to all applicable products." Also getting the same "SetSite failed for package [AWSToolkitPackage]" Please look at this!!! Im on windows 10 Pro |
I also have this issue. Windows 11 Pro 23H2 |
Myself and a colleague have the same issue too! |
Exactly same issue for developers at my org as of today (oh, hi Tony!) Cannot see the old extension listed in extension manager anymore, though the AWS Explorer still appears (if blank). SetSite error appear in the ActivityLog.xml. Cannot install the new version (with added Q!) as vsix installer says the extension is already installed. |
Hi, and thank you for sharing details (particularly the ActivityLog.xml contents) relating to installing version 1.54.0.0. We are actively looking into this at the moment. |
So the extension gets installed into Each version of the extension gets installed into a new folder within this location.
I'd be interested to know if any of your systems currently has more than one of these folders existing at the same time. |
Same issue here. Unable to uninstall even with CLI comments. Note: I have that file under only one location... |
The Toolkit writes a log per session of Visual Studio to |
log_2024-07-03_10-31-56_27244.txt |
Here is the error from ActivityLog.xml (referenced in pop-up error):
Microsoft.VisualStudio.Composition.CompositionFailedException: Expected 1 export(s) with contract name "Amazon.AWSToolkit.Context.IToolkitContextProvider" but found 0 after applying applicable constraints. |
First log file that I noticed the issue: toolkit-crash-log.txt Same solution, previous launch, which seemed to work fine: toolkit-ok-log.txt And to confirm I only have the |
|
You can uninstall this extension using VS installer. After that it could be installed again with extension manager. |
We have published a new version (1.54.0.1) to the extension marketplace. With this release,
Please share whether or not you have been able to start using the updated extension. If you had issues installing and starting version 1.54.0.0 of the extension, and also continue to see problems with version 1.54.0.1, please try the following:
(Update with additional troubleshooting steps)
|
The 1.54.0.1 version installed with no issues for me from within Visual Studio and seems to be working properly again. |
Mine only has p42bfph5.ab4 (which appears to be Amazon Q). Visual Studio now launches without the pop-up error, but AWS Explorer does not appear when I choose it from View. Extension Manager still doesn't show its presence. |
1.54.0.1 has fixed this. AWS Explorer now loads properly. Thanks. |
Im still having some issues. I uninstalled as was suggested and reinstalled version (1.54.0.1) When I load the following is displayed, If I attempt to deploy to AWS it fails after a while with the following error Log is here : |
Hi @awschristou, I followed your instructions and:
I can confirm that the AWS Explorer is now back (under the View menu) and that AWS Toolkit appears as a menu item under Extensions. I couldn't see the AWS Toolkit extension in the installed tab within the Extensions -> Managed Extensions window though. Thank you for getting a fix out so quickly. |
@tony-snoop hi are you able to deploy? ie when you right click a project and select "Publish to AWS" do you get all your options appear? |
Hi @Reynolds80 - We use an alternate method of publishing content to AWS using GIT and build triggers. So unfortunately I'm not sure if this works after uninstalling and re-installing the new AWS Toolkit update. EDIT: I tried the right click -> publish to AWS menu item... and it did appear to launch a tab with 4 publish ASP.NET target options. I don't recognise this dialogue - but it appears to be loading and working fine (I didn't go any further). |
@tony-snoop Thanks for checking! it fails for me before that point. This may point to maybe a role missing from my permissions, or something like that. More digging!! |
I've updated #441 (comment) with a suggestion to Repair your Visual Studio installation if you are seeing problems reported in this issue. |
@awschristou Hi I just did a Repair, and the Publish to AWS still fails. Error : "Publish to AWS failed to load publish details using the current credentials: AWS Explorer connects, and I'm able to see my databases/instances etc If I validate the connection I receive a Connection is Valid. Ill try the Publish to Elastic beanstalk (Legacy) next to see if that works. Edit: I was able to deploy using the Elastic beanstalk (Legacy) method! Very strange. |
Hi @Reynolds80 , if you are referring to the issue where you're seeing "Unable to start a deployment session" "A task was canceled" messages in Publish to AWS, can you please file that as a separate issue? |
The suggested fix - uninstalling the extension from a Visual Studio command prompt, rebooting, then re-installing from the marketplace, did appear to work. Until I then closed Visual Studio, and from a Unity project, double-clicked a script, which launches Visual Studio (and opens the project), at which point the toolkit was back in the broken state again, where it does not show as installed, and Q does not work (no "Q" icon at bottom), however in the Extensions menu, it still shows "AWS Toolkit". I tried exiting Visual Studio, and restarting with a non-Unity project, and it was still broken. I then uninstalled the extension from VS developer command prompt again, and re-installed from the .visx file (without rebooting) and it appears to be fixed again. I'm reluctant to launch it again from Unity for fear of breaking it again. |
It is broken again for me, completely. Uninstalling the extension from the command prompt and reinstalling no longer fixes it. Not sure whether it's VS 17.10.4 or AWS Toolkit 1.55.00 that's broken it, I haven't tried reinstalling VS, but that seems a rather heavy handed fix. |
Hi @paulguz-datapa , reinstalling VS would be heavy handed, and we don't know that it would definitely solve the problem, which we're still investigating. Something you can try is to have Visual Studio rebuild its cache of MEF components (the AWS Toolkit is partially composed of MEF components, and this is where we're seeing failures). If you install the Clear MEF Component Cache extension and run it (as shown on the marketplace page) and then restart Visual Studio, it would be useful to know if there is any change in the Toolkit's ability to initialize properly. |
Thanks @awschristou, but clearing the component cache has had no effect. |
Hi @paulguz-datapa , thanks for letting us know that you still have problems. We are now going to consolidate similar issues on an issue representing the core problem. Can you please have a look at #452, and if your system is still in a bad state, please follow through the "help us out" section to help us collect more data about the problem. If you are getting the "Some Toolkit components could not be initialized. Some functionality may not work during this IDE session." message, please comment on that issue going forward. Otherwise, please file a new issue, but try going through the guidance in 452. |
@awschristou OK, I've submitted the requested information to Microsoft. But when I run Visual Studio from the command prompt as requested, I don't get the AWS Toolkit error, so I'm not sure how much use that will be. After going through the full process as described in the MS ticket, Amazon Q was briefly working again. But after signing in to give Amazon Q permission, the next time I started VS, Amazon Q failed again. |
Describe the bug
Today AWS Toolkit extension cannot load properly on launching Visual Studio 2022. AWS Explorer is an empty pane. It is not even listed in Extension Manager anymore and cannot be uninstalled or overwritten by AWS Toolkit with Amazon Q.
To Reproduce
Launch Visual Studio. Alone or with solution. Above error will pop up.
Expected behavior
AWS Explorer load up properly with all service nodes.
Screenshots
Toolkit Logs
ActivityLog.xml
Development System (please complete the following information):
Additional context
AWS Toolkit with Amazon Q cannot be installed over.
The text was updated successfully, but these errors were encountered: