MATLAB: Download triaging data from metrics

bugfindercodeproverdownloadmetricsPolyspace Bug FinderPolyspace Bug Finder ServerPolyspace Code ProverPolyspace Code Prover Serverreport

We run the polyspace (bugfinder and codeprover) jobs in CI. CI generates a html report, which can be viewed by engineers. When a tag is applied, CI also uploads to the metrics server. Engineers then use the web interface and the javascript to perform triaging (severity, status, comment) on the found issues.
The html report that is exported from CI, does not contain the triaging data which happened on the server. So we would like to amend the results of local analysis with the most recent triaging data on the server.
I found the polyspace-results-repository command, but couldn't figure a way to download the triaging data and amend it to the recent local analysis. We need this both for bugfinder and codeprover.

Best Answer

Hi Stein,
Perhaps using the diff command ("polyspace-import-command") between previous analysis and current analysis would help. It provides a textual information about what have been reviewed, annotated and new.
To do so, you need to use the following workflow (using a pseudo-scripted way):
Get last result version polyspace-results-repository \
-server $ps_metrics_server \
-prog $my_project_name \
-product "Bug Finder" \
-get-versions-list
Then grep to get the last version downloaded from repository ($last_build_number).
Download last results in $last_results_folder
polyspace-results-repository -f \
-server $ps_metrics_server \
-prog $my_project \
-product "Bug Finder" \
-verif-version $last_build_number \
-download $last_results_folder
Diff results diffFile=$last_results_folder /diff.txt
polyspace-comments-import \
-print-new-results \
-diff-rte $last_results_dir $results_dir \
> $diffFile
Thanks,
David