Qodana 2023.1 Help

IDE integration

Starting from version 2022.3, you can use Qodana functionality in JetBrains IDEs for binding Qodana reports, both stored locally or in Qodana Cloud, with your project opened in an IDE. This means that you can:

This functionality is supported by IntelliJ IDEA, PhpStorm, WebStorm, Rider, GoLand, PyCharm, and Rider.

Before you start

  1. Make sure that your preferred IDE is installed via JetBrains Toolbox App.

  2. To open Qodana reports from your local storage, make sure that you previously opened the project by the IDE at least one time. This action establishes the link between the Qodana report and your IDE.

UI overview

Qodana is available in the Qodana tab of the Problems window of your IDE. This window is located in the lower-left part of the IDE user interface, and becomes visible once you open a report.

After opening, the Qodana tab shows the list of problems that were detected by Qodana.

Overview of the Qodana tab

If you click an item in this list, you can navigate to the highlighted code fragments that contain a problem.

Code highlighting from the Qodana IDE plugin

In the upper-left corner of this tab, you can find the buttons listed in this table:

Button

Description

Log in to Qodana

Logging in to Qodana Cloud. This action is a prerequisite for linking your project with Qodana Cloud-based reports. Alternatively, you can do it using the Tools | Qodana | Log in to Qodana menu of your IDE as described here.

Link project with Cloud

link your project with a specific report uploaded to Qodana Cloud. After linking, you can study the report using your IDE.Alternatively, you can link your project using the Tools | Qodana | Link Project with Cloud menu of your IDE as described here.

The Qodana tab buttons

Open report from Qodana UI

In a Qodana HTML report, choose a problem and click Open file in <IDE>.

The Open in IDE button

Open report from Qodana Cloud

Using your IDE, you can:

Log in to Qodana Cloud

Logging in to Qodana Cloud is required before linking your project with reports from Qodana Cloud.

  1. In your IDE, navigate to Tools | Qodana | Log in to Qodana.

    Logging into Qodana Cloud

    Alternatively, you can click the Log in to Qodana button of the Qodana tab.

  2. On the Settings | Tools | Qodana window, click Log in. This will redirect you to the authentication page.

    The log in button
  3. On the authentication page, complete the authentication step.

Link project with Qodana Cloud

You can synchronize your local project with reports uploaded to Qodana Cloud and related to a specific project. This lets you overview the detected problems using the Problems tool window of your IDE. To link a project, you first need to log in to Qodana Cloud.

  1. In your IDE, navigate to Tools | Qodana, and then click Link Project with Cloud.

    Linking the project with Qodana Cloud

    Alternatively, you can click the Link project with Cloud button of the Qodana tab.

  2. On the Link Project with Qodana Cloud window, select the Qodana Cloud project you would like to link your local project with, and then click Apply.

    The link project with Qodana Cloud window

After linking, you can overview the report using the Qodana tab of the Problems window, see the UI overview section.

Update report

To update the report, you should first have it linked with Qodana Cloud.

In your IDE, navigate to Tools | Qodana, uncheck Cloud Project <project-name>, and then check it back.

Updating the report using the Tools menu

Alternatively, in the Qodana tab of the Problems window, you can uncheck Cloud Project <project-name>, and then check it back.

Updating the report using the Qodana tab

Open report from a local storage

In the IDE, go to Tools | Qodana | Open Qodana Analysis report and select the qodana.sarif.json report file you would like to open.

Opening a local Qodana report

In the Qodana tab, you can overview the detected problems and jump to the corresponding line in the code editor. In case a problem was fixed before opening the qodana.sarif.json file, it is marked as [Not present].

Last modified: 12 June 2023