-
Notifications
You must be signed in to change notification settings - Fork 159
Closed as not planned
Labels
Description
Description
I realise this is not likely to be a real "bug", but I discovered an issue using dataclasses-json in conjunction with beartype>0.10.0 with dataclasses-json >0.5.8.
Beartype complains about:
beartype.roar.BeartypeDecorHintForwardRefException: Forward reference "dataclasses_json.api.SchemaType[A]" syntactically invalid as module attribute name.
Code snippet that reproduces the issue
from dataclasses import dataclass
from dataclasses_json import dataclass_json
from beartype import beartype
@beartype
@dataclass_json
@dataclass
class Testing(object):
data: str
t = Testing(data='thing')
print(t)
Describe the results you expected
beartype compatibility working
Python version you are using
3.11.3
Environment description
Working environments:
pip install -U beartype==0.15.0 dataclasses_json==0.5.8
pip install -U beartype==0.10.0 dataclasses_json==0.5.13
Failing environment:
pip install -U beartype==0.15.0 dataclasses_json==0.5.13