ruff icon indicating copy to clipboard operation
ruff copied to clipboard

Rule idea: Validate named imports

Open silverwind opened this issue 1 year ago • 0 comments
trafficstars

A rule to validate whether a named import exists on a imported file would be very useful, equivalent to this rule in JS. For example:

foo.py

def foo:
  pass

bar.py

from foo import foo, baz # error: named import 'baz' does not exist

silverwind avatar Apr 17 '24 10:04 silverwind