pcislo / vscode-nuget-gallery

MIT License
64 stars 19 forks source link

Error on initial load - no packages visible. #12

Closed zuc704 closed 4 years ago

zuc704 commented 4 years ago

Upon installing the extension and launching "Nuget: Open Gallery" from the command palette, a new tab opens, with the message "error."

image

pcislo commented 4 years ago

Could you open "Webview Developer Tools" from the command pallette and send me the content of the error shown in the console and the response from the server from the "https://azuresearch-usnc.nuget.org/query..." ?

Smoovsky commented 4 years ago

Could you open "Webview Developer Tools" from the command pallette and send me the content of the error shown in the console and the response from the server from the "https://azuresearch-usnc.nuget.org/query..." ?

Same problem here.

But after running open Webview Developer Tools from command pallette, nothing happened. I tried on two computers, both show nothing.

zuc704 commented 4 years ago

Hi, the following is all I'm getting after running webview dev tools:

console-1577652548902.log console-1577652533247.log console-1577653814694.log

Nothing I'm doing after loading the extension seems to cause anything else to show in console, but I ran the debugger and I'm seeing the following in transformResponse which is causing an issue in the "createQuery" function, which then seems to be returning "error":

SyntaxError: Unexpected token R in JSON at position 0

Stacktrace below:

c.transformResponse (VM110:formatted:441) (anonymous) (VM110:formatted:11360) x (VM110:formatted:11426) t.exports (VM110:formatted:11359) (anonymous) (VM110:formatted:9642) Promise.then (async) t.exports (VM110:formatted:9640) Promise.then (async) c.request (VM110:formatted:209) r.forEach.c. (VM110:formatted:220) (anonymous) (VM110:formatted:372) (anonymous) (VM110:formatted:10381) createQuery (VM110:formatted:10380) refresh (VM110:formatted:10430) refreshList (VM110:formatted:10525) v (VM110:formatted:7773) b (VM110:formatted:7800) m (VM110:formatted:7795) setTimeout (async) ku (VM110:formatted:7066) g (VM110:formatted:7778) k (VM110:formatted:7819) updateFilter (VM110:formatted:10557) filterChanged (VM110:formatted:9913) ne (VM110:formatted:1254) n (VM110:formatted:1384) ne (VM110:formatted:1254) t.$emit (VM110:formatted:2140) input (VM110:formatted:9964) ne (VM110:formatted:1254) n (VM110:formatted:1384) Qi.o._wrapper (VM110:formatted:3521)

Smoovsky commented 4 years ago

Could you open "Webview Developer Tools" from the command pallette and send me the content of the error shown in the console and the response from the server from the "https://azuresearch-usnc.nuget.org/query..." ?

I assume this response is causing the problem: image

pcislo commented 4 years ago

There was an error in the default configuration. The official nuget feed url was wrong. It should be "https://api.nuget.org/v3/index.json". I've fixed it in 0.0.6 release, but the url can be also changed in the configuration for the previous release (0.0.5).