Closed Numpsy closed 8 months ago
Note: I haven't been able to run the unit tests locally due to the issue I mentioned at https://github.com/ionide/FSharp.Analyzers.SDK/pull/182#issuecomment-1951337520
Would you mind adding a screen shot of the before and after that you see in your CI?
If I run my fun.build script with the current analyzers sdk version, I get this:
and with the modification I get this:
Also If I enable a binlog in the build, I now get warnings shown in the log:
whereas before I only had messages:
refs this 'determine what's a warning by pattern matching' behaviour in MSBuild I think? https://learn.microsoft.com/en-us/visualstudio/msbuild/msbuild-diagnostic-format-for-tasks?view=vs-2022
perfect, that's what I expected the cause to be - the SDK is now emitting errors matching the MSBuild Canonical Error Format.
… description from the rest with a ':' instead of '-'
Context: I've been trying to get the analyzer results integrated into a CI build at work, which is running in Azure DevOps.
I've got the SARIF results file being consumed by the MS SAST scans tab DevOps extension, and that appears to be working nicely. However, I though it might be nice if the results could be displayed as regular build warnings as well as in the sarif, so they just display in the main build output instead of you having to look at a different tab to see issues.
I couldn't get the results to show up as warnings, but then noticed that the analysers CLI tool currently outputs the results to the console with the final field separated from the rest with a
-
rather than the usual:
and it does seem that changing that causes the output to be recognised as warnings (complete with yellow text output rather than white).Is this a reasonable change to make?