You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Only simple default values are allowed for assignments. Similar to Y011, but for assignments rather than parameter annotations.
Y052
Y052 disallows assignments to constant values where the assignment does not have a type annotation. For example, x = 0 in the global namespace is ambiguous in a stub, as there are four different types that could be inferred for the variable x: int, Final[int], Literal[0], or Final[Literal[0]]. Enum members are excluded from this check, as are various special assignments such as all and match_args.
ruff seems to include Y52 in Y15 but does not exclude enums.
@sladyn98 I briefly looked into this. The pylint implementation of Y052 and Y015 appear together, it probably makes sense structure things similarly and place it near the ruff implementation of Y015.
flake8-pyi
ruff seems to include Y52 in Y15 but does not exclude enums.
in pyi file:
xref pandas-dev/pandas#53062 (comment)
The text was updated successfully, but these errors were encountered: