Details
Description
It appears that there is a problem with the LOC counter for the flex plug-in. I'll use the real life example from the flex plug-in page on the sonar website – http://nemo.sonarsource.org/dashboard/index/com.adobe:as3corelib
LOC – http://nemo.sonarsource.org/drilldown/measures/com.adobe:as3corelib?metric=ncloc
Physical lines – http://nemo.sonarsource.org/drilldown/measures/com.adobe:as3corelib?metric=lines
com.adobe.net.URI has roughly 2450 physical lines, but only 1 LOC according to Sonar.
Not all files are showing this problem, however.
Issue Links
- is superceded by
-
SONARPLUGINS-1906
Integrate Flex parser based on SSLR
-
Good catch, Josh!
I've made some tests, and the problem comes from FlexMetrics which fails to parse some files (like URI.as). The problem is that it fails silently, while printing out a report for the file in the "javancss-raw-report.xml" file (in which it sets every metric to '0', which is misleading for the Sonar Flex plugin...).
The bad news is that from what I can see on FlexMetrics (and more generally FlexPMD) website, those projects seem to be inactive and I'm afraid we won't get a fix for this