Some background information. I am using;
- Visual Studio 2013
- Using Visual Studio Online ( VSO ) with GIT
- Hosted Build Controller.
Everytime I went to edit a build definition, Visual Studio would throw and error as shown below in the image.
Team Foundation Error
Type 'Microsoft.TeamFoundation.Client.BasicAuthCredential' in assembly 'Microsoft.TeamFoundation.Client, Version=12.0.0.0,Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' is not marked as serializable
For a screenshot of the error displayed in Visual Studio Follow this link; Team Foundation Error
Link to Screenshot of Error
I searched for well over an hour for a solution to this issue and was about to give up until a found a blog post by Brian Misini which posted a solution to edit the generic credential.
Editing the credential did not work for me, but removing the credential altogether and restarting visual studio did the trick. Removing the credential has not proven to have any negative side affect as yet.
Hopefully this post will make it easier for others to find a solution to this problem when using search engines and also to give credit where credit is due to Brian Misini.
Solution: http://brian.minisi.net/2014/01/21/basicauthcredential-not-serializable/
Solution in Summary:
Reset your credentials
- Go to Control Panel > User Accounts > Manage Windows Credentials > In tab Generic Credentials, find the one for your TFS server and edit the credentials.
- If that doesn’t work, try removing the credential.