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
If a function argument contains multiplication, a C815 error ("... in Python 3.5+") is reported instead of C812, as if the expression includes tuple unpacking. This is misleading, because even Python 2.7 supports a trailing comma after multiplication.
Having a very quick look, this isn't immediately trivial to fix. The internal processing of tokens is done essentially one token at a time, whereas determining whether a token is a unpack token versus a multiplication (or an exponentiation) would require inspecting adjacent tokens.
This doesn't mean it's impossible to fix, however it does make it harder to fix and thus less appealing for what appears at this point to be a mostly cosmetic issue (given how far beyond EOL both Python 2 and 3.5 are).
I therefore don't have any immediate plans to fix this.
If a function argument contains multiplication, a C815 error ("... in Python 3.5+") is reported instead of C812, as if the expression includes tuple unpacking. This is misleading, because even Python 2.7 supports a trailing comma after multiplication.
Example Code
Actual Behavior
Expected Behavior
I would expect the error reported for line 10 to be C812, not C815.
Software Versions
Python 3.9
flake8-commas 2.0.0
The text was updated successfully, but these errors were encountered: