4

I am using the below version of Visual Studio, and I have logged in with my Azure DevOps Credentials. However, again and again, Visual Studio says "We need to refresh the credentials for this account. Re-enter your credentials". Please refer to the screenshot for reference. I have tried removing the account and adding it again. It stays there for some time and then it is asking again. Any suggestions on how to fix this would be very helpful.

Microsoft Visual Studio Community 2019 (2)
Version 16.10.2

Visual Studio 2019 Account Settings

4 Answers4

9

Try this:

in order to reduce the reauthentication, you can try to enable “System web browser” under Tools > Options > Environment > Accounts > Add and reauthenticate accounts using: dropdown. Then, sign in your accounts again.

More info here

ff8mania
  • 206
1

I had the same problem when opening a solution from a client. Their projects relied on Nugets from their Azure DevOps repo and everytime Visual Studio would try to restore those packages during build I'd be hit with the login popup forever. I had access to their DevOps, I could log in and read and edit bug reports and everything looked great, except VS2022 wouldn't have it.

I tried all sorts of account logout/login in VS2022, I switched to the system web browser and whatnot, but nothing helped. Until finally: In the VS build output the Nuget restore would complain about that remote package config, providing me with the exact .json URL. Following that link took me to a slightly different DevOps login, with more error messages. From there I logged out (again) and logged in again, which this time required the customer's 2-way authentication. After that, VS 2022 stopped asking and everything worked fine.

Apparently you can be logged in to DevOps in multiple ways at the same time, using the same account, and some login can remain while you log out everywhere else. The Visual Studio login prompt apparently can target the "wrong" login. Azure DevOps is a mess.

0

in this case you can do one more thing you can just remove you laptop credential if you are using windows thank go credential manager and after that go to windows credential and clear visual studio credential may be it will work

Uma
  • 1
-2

Stuck in the same loop.

I try to push or pull, VS asks for credentials, after submitting it just prompts it again 3 times, then I get the 'Failed to push to remote...' error with no logging in Output. I have reset everything related to credentials, account, remote connections, even reinstalled VS and tried every solution I could find online.

Pulling my hair out here.