Finite State Machine added the comment:
I doubt it's worth opening a separate issue for this, so I'll mention it here:
In the documentation
(https://docs.python.org/3.10/library/dataclasses.html#dataclasses.KW_ONLY)
nothing documents KW_ONLY as being new in Python 3.10.
-
Finite State Machine added the comment:
For what it's worth, I think a sensible exception message solves this problem.
While it would be nice to be able to use a field called 'mro', that's an
enhancement; the misleading except
New submission from Finite State Machine :
The following Python script:
from dataclasses import dataclass
@dataclass
class A:
mro: object
x: object
Results in the following unexpected exception:
Traceback (most recent call last):
File "/Users/dsuf