Skip to content

Auto Enforce Relative Imports Policy #583

@rmorshea

Description

@rmorshea

Current Situation

I tend to avoid relative imports that back out of the current directory. It can be discouraging to nitpick things like imports so we should automate this policy.

Proposed Actions

We should use a flake8 plugin that bans relative imports outside the current directory.

Work Items

Add flake8-tidy-imports with the following config:

[flake8]
ban-relative-imports = parents

Metadata

Metadata

Assignees

No one assigned

    Labels

    priority-3-lowMay be resolved one any timeline.type-governanceAbout management of this project

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions