-
Notifications
You must be signed in to change notification settings - Fork 83
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
Library Manager tool does not work on Visual Studio 2022 #699
Comments
Are you behind a proxy server by chance? If so, can you determine if the proxy server is blocking your requests? |
I'm on the standalone PC without proxies. |
RESOLVED it with changing project file to newer version: I have same issue. I have a project of 2020 which I need to debug. I have errors on build: I did remove the libraries from www\lib and did install libman 2.1.175+29a28921bd.RR My solution has multiple projects and to use libman clean/ restore I needed to move one directory folder up where my libman.json is located. Maybe that is the problem? |
What do you mean under this?
Problem still exists. |
Problem still existing on my base PC and not even raised on my laptop (same network configuration), even after VS updated to 17.4.0 version. |
Same version. Tried to change and restore back - still no results. Problem is that it even does not show any libs in the list, when you typing project start letters.... |
Is it possible to get a guide "how to run this extension in debug?" somehow? To try to debug and understand what is going wrong? |
For debugging the VS extension, the steps should be:
This will launch the experimental instance of VS (intended for testing extensions, won't affect your main VS install). For the dotnet tool, you can also build from VS and set it as the startup project to F5, or launch it on the command line using For the MSBuild tasks, you need to build them, then create a project that references your private build of the nuget package. To ease debugging, insert There's a build.cmd script in the repo root that will build everything (.cmd implies it's for Windows only, but it's just a wrapper to call This is lacking from the README but it's a good idea to put there. Feel free to submit a PR, or I'll add this to my todo list as soon as I have time. |
@LLIAMAH Thanks for the write-up! Can you clarify a couple details?
|
Results - Nr.2 answer on this ;).
I don't have Win11 to check this :\ |
Found additional problem: So it is required to be fixed somehow. |
Sorry for accidental closing - but it is required to resolve problem. |
BTW it could be catched exception 'The request was aborted: Could not create SSL/TLS secure channel." (don't forget that it is Internal Exception) and applied retry with something like:
|
It it possible to know approximate date when will be some fix? |
I set up a VM with Windows 10, same build as yours, but I can't reproduce this issue yet after trying for several hours. I've tried every combination of TLS settings available in the Internet Options, but they all work fine for me with any libman provider. It's quite vexing that I can't reproduce the problems you're experiencing, whether with TLS 1.3, 1.2, or with older deprecated versions, so I'm having a hard time validating any potential solutions. I'm wary of making a change to hard-code a TLS version, as everything older than TLS 1.2 is already deprecated for security issues - I'm sure it's only a matter of time before 1.2 is broken as well, which is why it's best to use the OS defaults, as those will be updated by OS security patches as needed. I'd recommend disabling the older versions off on your desktop as well, unless you frequent sites that don't support TLS 1.2. |
I'm agree with you that it is bad decision to hardcode this thing, but isn't better to set try...catch block for AuthenticationFailed error? Cause info about problem - I didn't find in any log at all: BTW did some experiments with HttpClient and found that default (without properly configured handler) behavior return 4-levels Exception: But all this respond surrounded by the first one: An error occurred while sending the request - that's all. |
I don't think doing a manual backoff (reducing TLS versions) is useful outside of debugging. It can lead to other error states (for example, JSDelivr doesn't support anything below TLS 1.2, so a request with only 1.1 will fail to negotiate), and it's a security step I'm not willing to make at this time, not until we have a larger number of reports with this as a consistent issue. Improving the logging is important and has come up a number of other times (such as in #601 and #697). For now, I'd recommend that you uncheck the TLS 1.3 on your desktop since that was verified to work around the problem. I don't know why it causes problems for you but not for me on a similar machine. |
Per aspnet#711 (and aspnet#699 before it), some users need to force TLS 1.2 for libman to work. This change adds a new user setting, "forcetls12", which will set libman to use TLS1.2 for any HttpClient it creates. I verified via WireShark that the traffic to services (cdnjs, etc) that libman calls to switched from 1.3 (my system default) to 1.2 when this setting was in place, and returned to 1.3 by unsetting it. I could also see that other connections from within VS were still using TLS1.3 so we didn't affect other components on accident.
Is your feature request related to a problem? Please describe.
UPDATE: autocomplete has been lost - don't work since today (14.Sep.2022)
So it is impossible to Add-Client Libs via visual studio - cdnjs is not available at all, jsdelivr - cannot download full set of files - continuously fails.
Found this problem in last 2-3 weeks.
Errors tab shows the Code of Error: LIB010
I’ve checked the official reference: https://github.com/aspnet/LibraryManager/wiki/Error-codes
LibraryManager error codes final code number - LIB007
During search of solution tried to update:
Describe the solution you'd like
Add-Client lib must add libs in "wwwroot" folder of the Asp.NET Core projects
Additional context
Tried solution described here
dotnet tool install -g Microsoft.Web.LibraryManager.Cli
Then go to the folder where libman.json is located and run:
libman cache clean
libman restore
It does not help!
Problem could be visible here in developer community
The text was updated successfully, but these errors were encountered: