I still experience the problem with Linqpad 6.5.5. It throws me an exception Unauthorized.
I tried with several combinations it with the PAT, user name and password and none worked.
Does anybody experience the same issue?
I have recently switched to LinqPad 6 (6.7.5 x64) and I'm experiencing this issue. We have an on-prem Azure DevOps instance. I've created a PAT with all scopes. I created a nuget feed in LinqPad and left the username blank and the password is the PAT token. I keep getting the authentication 401 error.
FYI, I tested this and without changing the feed at all the feed works in LinqPad 5 but not 6. I get the 401 error in LinqPad 6.
Have you re-started LINQPad after changing the username/password? (This is required by the NuGet API)
I can confirm that using PAT in LinqPad 6 (v6.8.3) doesn't work , but the exact same configuration works in LinqPad 5 (v5.41.00). I have tried different configurations (v2, v3, PAT with and without username etc.), but no luck - still gets a 401. I hope this gets fixed soon, as I would like to use C# 8 features.
I still can't reproduce this error. My devops feed URI looks like this:
The username box contains 'ID', although it seems anything can go here (as long as it's not blank).
The password box contains the PAT.
Note that you must restart LINQPad after editing the credentials - this is because the NuGet client library caches the credentials after they're first sent and there appears to be no way to clear that cache.
Had 401 error on v6.8.3 until I followed Joe's notes. 1. Ensure Id field has something in it, password is PAT. 2. Save. 3. Restart linqpad. All good!
I still can't get it to work (now running version 6.9.15). However, I have a few things to add.
I have both version 5 and 6 installed at the same time. Changes to "Package Source" in one seems to affect the other. It looks like I don't have to put anything in the "Username" and "Password" fields in version 5 for it to work. But I still get the 401 (Unauthorized) in version 6. So I think this problem might not have anything to do with the PAT (for me at least).
What I have noticed is that the source shown in the message is different from the source in "Package Source". In stead of "https://[base path]/_packaging/[feed name]/nuget/v3/index.json" I get a message saying that "Failed to retrieve metadata from source 'https://[base path]/_packaging/[some guid]/v3/query2/?q=...'".
So LinqPad v6 seems to try to contact a source it doesn't have access to, whereas v5 does not.
I don't know if this helps at all, but I hope it does.
Got 5 and 6 here too. Same v6 as you. Both work for me. My V6 is an XCopy deploy not an install, but I dont know if that makes any difference ?
In my nuget setup I have my source as https://xxxx.pkgs.visualstudio.com/_packaging/xxxx/nuget/v3/index.json, I have "ID" (without quotes) as the Username and Personal Access Token from AzDevops for password.