5.1.4.5. Issue Details

The Issue View can be opened from several locations, most notably from the Issue Table, but also from other Issue Views and File Views via the issue kind icons.

The Issue View displays the source location(s) of an issue along with their surroundings, as well as other metadata about the issue. This metadata includes affected architectural components, affected entities, a short error description, and other relevant details. A chart highlights the version ranges during which the displayed issue was active on a linear time axis; you can also add tags and comments to the issue.

A version slider above the code viewer allows you to view the issue in different versions of your source code. If you select a version where the issue does not exist, you will still see the source code where the issue was last detected, along with the details it had at that time. This is useful for reviewing how an issue was resolved. You can tell you are viewing an issue that no longer exists by the red analysis version dates in the sidebar. Additionally, no current issue will be highlighted in the source code; only the usual grey highlighting for other issues will be visible.

Furthermore, the code viewer includes a toolbar for adjusting viewer settings and interacting with the file content. These tools are identical to those available in the File View. The toolbar includes a find button to search file content (equivalent to pressing Ctrl + F when the code viewer has focus), a button to download the current file, a button to open the file for editing, and a settings button to fine-tune the viewer’s appearance to your specific needs.

If you have the necessary permissions for the current project, you can view the issue owner information in the details panel on the right. This information is highlighted in red if more than one user is responsible for the given issue.

In the tabular metadata on the right, a small pencil icon next to each issue location allows you to open the file containing that location in your preferred editor.

IssueView showing a Dead Entity

IssueView showing a Dead Entity dashboard2-uiicon-deadcode

The source code is displayed similarly to the File View, but the code location affected by the issue is highlighted in a prominent color. You can also select a different version. If the issue does not exist in the selected version, no highlighting will appear, but the Issue View will still attempt to display the same file. Note that this is not possible if the file does not exist in the selected version. You can also jump to a specific line using the Ctrl+G shortcut.

The presentation varies depending on the issue type. Architecture Violations dashboard2-uiicon-architectureviolation, Clones dashboard2-uiicon-clone, and Cyclic Dependencies dashboard2-uiicon-cyclicdependency are typically presented in two adjacent code windows showing the involved snippets side-by-side. In this example, a Clone dashboard2-uiicon-clone is shown, with highlighting marking the cloned areas as well as the differences between the two similar code fragments.

Issue View showing a Clone

Issue View showing a Clone dashboard2-uiicon-clone

Visualizations / Preview Images

For certain Issue Kinds – currently Architecture Violations dashboard2-uiicon-architectureviolation and Cyclic Dependencies dashboard2-uiicon-cyclicdependency – visualizations are provided to help you better understand the issue.

Issue View showing an Architecture Violation

Issue View showing an Architecture Violation dashboard2-uiicon-architectureviolation

These images are generated by default. If you encounter any problems, consult the corresponding option documentation for Architecture Violations dashboard2-uiicon-architectureviolation and for Cyclic Dependencies dashboard2-uiicon-cyclicdependency.

Rule Texts

For most issues, we provide additional explanations, such as the specific rule that was violated, to aid further investigation. In the example, a MISRA rule violation is shown, with the rule text provided as an excerpt from the MisraC2012 ruleset. For some rulesets (currently MISRA and AUTOSAR), the link in the footer can be configured in the Rules section to point to a custom location.

IssueView showing a violation of a Misra Rule

IssueView showing a Style Violation dashboard2-uiicon-styleviolation of a MISRA Rule

Timeline

The sidebar also contains the Timeline panel, which is primarily used for Metric Violations dashboard2-uiicon-metricviolation. For these issues, it displays the development of the corresponding Metric value over time.

IssueView showing a Metric Violation and a plot of the Metric over time

IssueView showing a Metric Violation dashboard2-uiicon-metricviolation and a plot of the Metric over time

For other Issue Kinds, the plot visualizes the version range during which the issue was active.

Owners

Issue Owners are determined by the Analysis configuration, which typically consults the Version Control System.

When a version is analyzed and an issue is detected, the Version Control System is typically queried for information such as the last user who modified the line of source code where the issue was found.

For Issues involving multiple relevant lines of code, e.g., a Clone dashboard2-uiicon-clone or a Cycle dashboard2-uiicon-cyclicdependency, the Analysis often assigns multiple owners.

Owners can also be assigned in other ways, e.g., by mapping file patterns to users, marking files as owned by NOBODY, or mapping issues from one user to another.

Because viewing issue ownership can be sensitive, a separate permission is required to view Issue Owners or to filter the Issue Table by specific Owners.

Most importantly, ownership determines whether an issue appears in a Dashboard User’s list of own issues and, consequently, which issues trigger (by default) the Erosion Notifications upon their appearance or disappearance.

Suppressions and Justifications

A Suppression is an issue property that determines whether an issue is displayed by default in the Dashboard or whether it is imported into the Dashboard at all.

A Justification is an explicitly provided short text describing why an issue found by the analysis is being tolerated instead of fixed by changing the code.

They are configured via the Analysis Configuration.

Suppressions and Justifications are not editable from the Dashboard, as the intent is to keep them as close to the source location of the issue as possible; however, it is also possible to define them for entire files.

Ideally, a Suppression is accompanied by a Justification at the source location, but this is optional; in fact, a Justification can be provided without a Suppression.

The import of Suppressed issues into the analysis results database must be explicitly enabled per project; by default, Suppressed issues are dropped.

If the import of Suppressed issues is enabled, the predefined Named Filter called Hide Suppressed will be used by default in the Issue Table instead of Show All. The corresponding Suppressed table column is only available in this case. The Issue View and the File View then also show the checkbox Show suppressed issues next to the version selector. It is unchecked by default. Only when checked does the code viewer also mark the locations of Suppressed issues.

Note

Whether to combine a Justification with a Suppression depends on your workflow. However, keep in mind that if you choose not to import suppressed issues, their Justifications will only be imported if the justified issue is not suppressed.

Annotations

Issue Annotations are special properties of an issue that can be added post-analysis (i.e., from the Dashboard only). The analysis is unaware of them. For more information, see the chapter on Issue Annotations.