Open the msbuild.binlog file in MSBuild Structured Log Viewer using the 'de-AT' culture:
Set-Culture 'de-AT'
./msbuild.binlog
Expected
Correct execution time is displayed for all analyzers under Analyzer Summary.
Actual
0 ms is displayed for all analyzers under Analyzer Summary.
Cause
No NumberFormat/CultureInfo is specified in Microsoft.Build.Logging.StructuredLogger.CscTaskAnalyzer.AnalyzerAssemblyData.FromFolder > ParseLine when parsing the execution time.
Workaround
Use Set-Culture 'en-US' or something similar before starting MSBuild Structured Log Viewer.
Suggested Fix
Use the culture (CurrentUICulture?) value from the log file to parse the execution time.
Found in version: 2.1.820
Steps to reproduce:
Use the 'en-US' culture:
Create a new example project:
Enable code analysis, build the example project and generate a msbuild.binlog file:
Open the msbuild.binlog file in MSBuild Structured Log Viewer using the 'de-AT' culture:
Expected
Correct execution time is displayed for all analyzers under Analyzer Summary.
Actual
0 ms
is displayed for all analyzers under Analyzer Summary.Cause
No NumberFormat/CultureInfo is specified in Microsoft.Build.Logging.StructuredLogger.CscTaskAnalyzer.AnalyzerAssemblyData.FromFolder > ParseLine when parsing the execution time.
Workaround
Use
Set-Culture 'en-US'
or something similar before starting MSBuild Structured Log Viewer.Suggested Fix
Use the culture (CurrentUICulture?) value from the log file to parse the execution time.