-
Notifications
You must be signed in to change notification settings - Fork 216
Closed
astral-sh/ruff
#21370Labels
bugSomething isn't workingSomething isn't workingimportsModule resolution, site-packages discovery, import-related diagnosticsModule resolution, site-packages discovery, import-related diagnostics
Description
This is a followup to astral-sh/ruff#21173 and pertains to behaviours described in imports/nonstandard_conventions.md
The "first from first serve" rule says it applies to the "first time in this scope (or any parent scope)", but we actually only implement "first time in the entire file" which doesn't make sense but was easy to implement and worked well. There is a test in that file that currently demonstrates the failure mode of this (two functions import a submodule, only the first function gets the submodule as a local).
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingimportsModule resolution, site-packages discovery, import-related diagnosticsModule resolution, site-packages discovery, import-related diagnostics