Strange Code Analysis Problem About TFS 2010 Build - visual-studio-2010

I have got strange problems in the last few days. Today's strange problem is about Code Analysis and TFS 2010 Builds.
After we had upgraded our TFS from 2008 to 2010, we then upgraded our solutions from Visual Studio 2008 to 2010. There were no errors while upgrading, but we saw strange things about code analysis.
Shortly the problem is, FxCop results differ by running automatically from tfs 2010 build or running manually from command prompt. Even though they are both using the same command parameters and values.
For example i̇f i run FxCop in the TFS build, I get 7 errors, but i̇f I run FxCop by command prompt using the command I see in the build log, I get 133 errors.
What could cause these differences?

Have you verified that your VS and command line analysis runs are using the same rule sets?

I solved this problem.
It was about CustomDictionary path.
I deleted FXCop\CustomDictionary.xml for test and forget. I replaced CustomDictionary and everything became normal.

Related

Visual Studio 2017 Error in Test Property Page

There is an issue with my Visual Studio / Test Property Page. Which is I guess one of the root causes to not discovering any of my tests, in any of my projects. So this means it is not related to one Project, or to one nuget package on the projects. I am not sure when the issue first occurred, but I am suspecting, after some Visual Studio updates.
After following some of the possible solutions on SO, related to the Test Explorer, the tests itself and the Test property Page. I found the following:
When I go in Tools -> Options -> Test. I have the error shown above.
Error: "An error occurred loading this property page"
It is not an issue of missing nuget packages. Because it is happening in all of my projects.
The latest .NET framework is installed
All of the questions on SO, related to this topic, didn't have something that could help me solve this issue. Unless I missed something, which is quite possible.
Re installation of Visual Studio itself didn't help. The issue persists.
Deleting VS test cache files DEL %TEMP%\VisualStudioTestExplorerExtensions
Restarting VS
Test -> Test Settings -> Default processor architecture is set to x86
Based on my research, I find a case which has the same error message with yours. The issue was resolved by running “devenv /setup” in Visual Studio 2017 Command Prompt.
I’m not sure if this works on you machine. Please try it, I do hope it is helpful.
It worked for me! (On VS 2019 version)
Open Developer Command Prompt for VS 2019 Preview
Run devenv /resetuserdata
I encountered the same problem in Visual Studio 2019. I was helped by the "Visual Studio 2019 Command Prompt" with the "devenv /updateconfiguration" command. After that, when I started the Visual Studio, there in the settings the Test tab worked.
I spotted the solution here, but did only step 4:
https://github.com/dotnet/roslyn/issues/9421#issuecomment-191895696

DEVENV Command line build fails with: "This operation may only take place in the UI thread"

we virtualized our build server and having issues building some c++ projects.
It is a win7 (we have some vb6 projects) with visual studio 2017.
When I build a project it just errors out with "This operation may only take place in the UI thread".
Also it is completely random...sometimes it compiles, sometimes it does not.
I have no idea why and what I could try to fix it. I have also a Win10 build machine where the problem does not happen. We want to stick with the Win7 build machine though, because on the Win10 one we got issues with some vb6 projects.
If I use msbuild it works fine, I would rather not replace all devenv calls for now though.
Anyone an idea what the issue could be or how to debug it?
Seems to be an issue with Visual Studio 2017 15.6.x. works fine with 15.5.7

Visual Studio 2013 hanging on getting latest from TFS

In my Visual Studio 2013 I'm trying to get the latest version of a project from TFS but this hangs on until the timeout error occurs.
I've tried deleting the Team Explorer cache a couple of times, undo all the changes, restart, rebuild but still the same issue.
What's even more interesting is that there someone else in my team with a similar version of Visual Studio that hangs when getting the latest on the same project.
We're using VSO so I was expecting this will not have issues.
Any ideas?
Thanks,
Andrei
Please make sure if you are running antivirus that your work space is excluded from the rules. Otherwise it has to check each and every file which is a major slow down. Also check your local work space to see if the files are getting copied. Check the event log on the TFS server it may have a reason. Also try using the VS command line to make the same request.

F# compilation hangs in Visual Studio

I've got a solution containing a mixture of C# and F# projects (it's a Silverlight app). When I attempt to compile it in Visual Studio 2010 SP1, the build process hangs on one of the F# projects. If I remove that project, it hangs on a different F# project.
The F# compiler (fsc.exe) isn't running, and I can't find any likely-looking process to kill (other than devenv.exe).
It compiles fine on the command line, using MSBuild. It compiles fine in VS11 beta. We can't (yet) migrate the solution to VS11.
This occurs on my PC, and one other PC. None of the other team members have this problem.
Has anyone seen this behaviour before? How do I go about debugging this?
It may be useful to go to Tools\Options\Projects&Solutions\Build&Run and change MSBuild output verbosity to 'diagnostic' and then check the output window to see exactly where things are getting hung, that may help diagnose.

Resharper 6 simply ignores all my tests

I have a solution with a lot of nunit tests in different projects. When I run resharpers testrunner, it finds all the tests. But when it comes to execution it simply marks them all as grey and silently completes.
How do I figure out whats wrong with the testrunner, and most importantly how do I get it to run my tests.
I have resharper 6 in visual studio 2008. My code is on a fileshare, and everything runs in a virtual machine.
Jetbrains has confirmed this to be a bug. That resharper wont run nunit tests located on a networkshare. They'll try to fix it in 6.1.
You can find the ticket here:
http://youtrack.jetbrains.net/issue/RSRP-275538

Resources