aliasadidev / vscode-npm-gui

vscode nuget package manager gui https://marketplace.visualstudio.com/items?itemName=aliasadidev.nugetpackagemanagergui
MIT License
46 stars 17 forks source link

I configured a custom source and it doesn't seem to work #63

Open dodu2014 opened 1 year ago

dodu2014 commented 1 year ago
"nugetpackagemanagergui.packageSources": [
    {
      "sourceName": "BaGet",
      "searchUrl": "https://nuget.mydomain.com/v3/search",
      "packageUrl": "https://nuget.mydomain.com/packages/{{packageName}}",
      "packageVersionsUrl": "https://nuget.mydomain.com/v3/package/{{packageName}}/index.json",
      "sourceType": "server"
    }
  ]

Baget type based hosting, can you help me see where the problem is?

jeremy-allocate commented 11 months ago

I did the same today and got the same problem, it just sits there trying to connect forever when I run a search via the plugin even though it shows the new source on the search page. I can reach baget in the browser and upload to it just fine though.

My settings are identical to yours aside from the domain:port...

jeremy-allocate commented 11 months ago

Also, this view in the marketplace (just the readme?) is missing a baget URL (packageUrl specifically):

image

careless6666 commented 8 months ago

I have same problem, i configure all url and check that return data in my browser

{
    "C_Cpp.default.compilerPath": "/usr/bin/gcc",
    "omnisharp.enableDecompilationSupport": true,
    "omnisharp.enableRoslynAnalyzers": true,
    "dotnet.completion.showCompletionItemsFromUnimportedNamespaces": true,
    "nugetpackagemanagergui.packageSources": [
        {
            "sourceName": "name",
            "preRelease": true,
            "packageVersionsUrl": "https://nexus.domain/repository/nuget-hosted/v3/content/{{packageName}}/index.json",
            "packageUrl": "https://nexus.domain/repository/nuget-group/{{packageName}}",
            "searchUrl": "https://nexus.domain/repository/nuget-hosted/v3/query/0",
            "sourceType": "server"
        }
    ]
}
thepaleone commented 5 months ago

I'm facing the same issue using a custom installation of Baget. My settings are the same as @dodu2014 other than the domain. I've tried debugging but the developer console doesn't have any additional information that I can find. Looking through the source code (I'm not a TypeScript dev so take with a grain of salt) I can't seem to tell exactly what it's doing, but my suspicion is that it has a problem when there's more than one URL, almost like it's not handling the array properly. 100% guessing there and likely very wrong, but I wanted to provide as much detail as I could.

andyqp commented 4 months ago

It is very important to get the "authorization" part right. Even if you can open the configured URLs in browser, it could be that the browser has cached the authorization info. That information is not accessible from the plugin, so you must fully specify the "authorization" structure in the source definition.

thepaleone commented 4 months ago

Hi @andyqp, I believe I've done that. The source does not require authorization so I chose "none" per the docs. I tried both with and without the username and password (specified as an empty string). I've also tired it removing the `authorization" completely. Same results for all.

"authorization": {
    "type": "none",
    "username": "",
    "password": ""
},

and

"authorization": {
    "type": "none"
},
aliasadidev commented 4 months ago

@thepaleone @andyqp @careless6666 @jeremy-allocate @dodu2014

Could you please provide the following information:

thepaleone commented 4 months ago

It's been doing this for several months so the some of the component versions have updated over time, but currently they are:

As of this writing it's the most recent of all components.