When running ruget view versions
for a package that uses legacy NuGet versioning (e.g.: 0.4.1901.2905), ruget fails with a ruget::api::bad_json
diagnostic:
$ cargo +nightly run -- view versions Microsoft.Quantum.IQSharp
Finished dev [unoptimized + debuginfo] target(s) in 0.44s
Running `target\debug\ruget.exe view versions Microsoft.Quantum.IQSharp`
Error: ────[ruget::api::bad_json]────────────────────
× Received some bad JSON from the source. Unable to parse.
╰─▶ missing field `foo` at line 1 column 1648
╭───[https://api.nuget.org/v3/registration5-gz-semver2/microsoft.quantum.iqsharp/index.json:1:1607] JSON context...:
1 │ rp"],"title":"","version":"0.4.1901.2905"},"packageContent":"https://api.nuget.o
· ┬
· ╰─ here
‽ This is a bug. It might be in ruget, or it might be in the source you're using, but it's definitely a bug and should be reported.
error: process didn't exit successfully: `target\debug\ruget.exe view versions Microsoft.Quantum.IQSharp` (exit code: 1)