PyCharm 2018.2 Help

Configuring Inspection for Different Scopes

By default, all enabled code inspections analyze all files in your project. Depending on your needs, you can run the same inspection in more than one scope of files with different settings.

If one file is included in two or more scopes, and you enable an inspection in these scopes, PyCharm will process them according to their order in the list of scopes — the uppermost scope will have the highest priority, and therefore, it will be analyzed first.

  1. In the Settings/Preferences dialog (Ctrl+Alt+S), select Editor | Inspection.

  2. Select any inspection from the list.

  3. From the In All Scopes list, select Edit Scopes Order.

  4. Select the necessary scope, and use the icons actions up and icons actions down buttons to move it up and down the list.

    py scopes order
  5. If needed, create a new scope. To do so, click artwork studio icons avd edit (Edit Scopes), specify scope settings, and select the files and folders that you want to include in it.

    py new scope
Last modified: 12 October 2018

See Also

Procedures:

Concepts: