Navigation Menu

Skip to content
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

nuget list command failed #187

Closed
timiil opened this issue Jan 2, 2019 · 14 comments
Closed

nuget list command failed #187

timiil opened this issue Jan 2, 2019 · 14 comments

Comments

@timiil
Copy link

timiil commented Jan 2, 2019

Describe the bug

when i run below command line:

nuget list -s http://get.blabla.com

the response is:

“doctype”是意外的标记。标记应为“DOCTYPE”。 第 1 行,位置 3。
"doctype"  is exception mark, should be "DOCTYPE". line 1, position 3.

by the way, in visual studio 2017, when i add the 'http://get.balbla.com' as a new nuget server source, i get the same error message. any help very thanks.

@WernerMairl
Copy link
Contributor

hi,
please provide more information about your setup ...

Question:

The „是意外的标记。标记应为“ is coming from the configuration or from data (nuge package)
if it comes from data, can you provide the nuget package or at least the nuspec ?

regards
Werner

@loic-sharma
Copy link
Owner

loic-sharma commented Jan 29, 2019

Hey @timiil, I apologize for the long response time. It seems that you're package source is incorrect. If you're running on localhost, this would be http://localhost:5000/v3/index.json. I'm not sure how your server is setup, but I would try http://get.blabla.com/v3/index.json as your source. Please let me know if you have any additional questions!

@loic-sharma
Copy link
Owner

Also, the nuget list command won't work until the the V2 APIs are implemented on BaGet (this is tracked by #43).

@stamepicmorg
Copy link

stamepicmorg commented Apr 3, 2019

@loic-sharma, Hello! i have tried it with "/v3/index.json" and it not working too.

123


can u plese look at fixes from @tomzo? #43 (comment)

his commit: ai-traders@dcd815a


alternative pr: #178

@loic-sharma
Copy link
Owner

@stamepicmorg I'll likely add in these legacy APIs at some point, but this isn't a very high priority for me. What're you using nuget list for? FYI, this command is now deprecated and will be removed in future versions of NuGet. See NuGet/Announcements#34

@stamepicmorg
Copy link

stamepicmorg commented Apr 4, 2019

@loic-sharma thanks for reply!

if I understand correctly, nuget.exe is not complete compatible with the baget? (because it use old v2 api but nuget-server migrating to new api v3).


can you give me advice please?

i successfully can download and update my packets, but i cant search. if i want to search packets\get list from my private repo on client should i go another way? should i use nuget.client library for example?

@timiil
Copy link
Author

timiil commented Apr 11, 2019

Hey @timiil, I apologize for the long response time. It seems that you're package source is incorrect. If you're running on localhost, this would be http://localhost:5000/v3/index.json. I'm not sure how your server is setup, but I would try http://get.blabla.com/v3/index.json as your source. Please let me know if you have any additional questions!

thanks for you reply, but the response is :

D:\code\gateway\Deploy>nuget list -s http://get.xxxxxxx.com/v3/index.json
警告: This version of nuget.exe does not support listing packages from package source 'http://get.xxxxxxxx.com/v3/index.json'.
找不到程序包。

(the above Chinese say that "can not find the package ...")

FYI, i am using the newest (2019/04/11 updated)docker image to run baget:

docker run --rm --name baget -p 1601:80 --env-file /home/baget/baget.env -v /home/baget/appsettings.json:/app/appsettings.json -v /home/baget/data:/var/baget loicsharma/baget

@VitaliiIsaenko
Copy link

@loic-sharma thanks for reply!

if I understand correctly, nuget.exe is not complete compatible with the baget? (because it use old v2 api but nuget-server migrating to new api v3).

can you give me advice please?

i successfully can download and update my packets, but i cant search. if i want to search packets\get list from my private repo on client should i go another way? should i use nuget.client library for example?

I have exactly the same issue, I achieved running it and I can even push packages to the server, but I cannot search for them and even download a package. @stamepicmorg did you already find a solution for this?

@stamepicmorg
Copy link

stamepicmorg commented Jul 9, 2019

did you already find a solution for this?

yep. now i am using another solution and all fine. lol.

@triumlabs
Copy link

@stamepicmorg What solution could you find for searching nuget packages? Can you share it?
I tried nuget 5.0.2, but can't list packages from command line, however, Visual Studio 2017 can use BaGet without any problem.

@stamepicmorg
Copy link

@triumlabs i temprerary switched to custom nuget-php realisation. and i testing trial installation of artifactory (but i dont like it).

I'm still very much looking forward to adding support to the baget 👀

@stamepicmorg
Copy link

hello! any updates?

@loic-sharma
Copy link
Owner

loic-sharma commented Jun 28, 2020

if I understand correctly, nuget.exe is not complete compatible with the baget? (because it use old v2 api but nuget-server migrating to new api v3).

Yes that's correct. BaGet supports the latest NuGet protocol. All dotnet CLI features should work as expected while using BaGet.

However, BaGet does not support the legacy V2 protocol. As a result, some features on nuget.exe, like nuget list, are currently broken. Adding support for the legacy V2 protocol is still not a very high priority for me. I work on BaGet mainly for fun in my free time, reverse engineering a legacy protocol is not very fun 😥

i successfully can download and update my packets, but i cant search. if i want to search packets\get list from my private repo on client should i go another way? should i use nuget.client library for example?

Here are some options:

  1. BaGet's website has a UI that lets you search for packages
  2. You can add BaGet as a package source on Visual Studio, Visual Studio for Mac, or Rider. These IDEs support searching through your package sources
  3. I've also created a CLI app nugs that you can use to search against a NuGet server (note that my prototype only supports nuget.org). We're working on integrating this into NuGet itself, see this spec: Created SearchCommandSpec.md NuGet/Home#9718
  4. You can use BaGet's SDK to create your own app to search for packages: https://loic-sharma.github.io/BaGet/tools/sdk/#search-for-packages

@jpylypiw
Copy link

Hello everybody!
I stumbled across the project today and installed the system in-house. We want to use the system for nuget packages from different departments.
There are also chocolatey packages in the administration team. Since chocolatey is currently using the v2 nuget API the package installation is currently not working.
Chocolatey will not implement the v3 API in the near future.
There is an open issue chocolatey/choco#508 from chocolatey.
At BaGet I found an open merge request #294 that would allow the use of Chocolatey.
Is it possible to check and merge the merge request?

@timiil timiil closed this as completed Apr 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants