Skip to content

N816 considers generator/list comprehensions to be globally scoped #233

Open
@ember91

Description

The following will trigger N816 twice:

(someVar1 == 8 for someVar1 in [])
[someVar2 == 8 for someVar2 in []]

N816 is explained as "mixedCase variable in global scope".

But are they really globals? Should there not be a new error code Nxyz for this? Or is it a limitation or shortcut in pep8-naming that leads to this behavior?

Version: 0.14.1

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions