-
Notifications
You must be signed in to change notification settings - Fork 24
Open
Description
Describe the bug
In the generated dataclass code a "normal" false appears instead of the python version.
To Reproduce
Steps to reproduce the behavior:
- Create a
CREATE TABLEstatement, containing this column:edited boolean DEFAULT false, - Generate the dataclass:
create_models(ddl, models_type="dataclass") - The dataclass has this line:
edited: Optional[bool] = false
Expected behavior
false -> False
Screenshots
CREATE TABLE Material
(
id integer,
name string,
edited boolean DEFAULT false,
deleted boolean DEFAULT true,
PRIMARY KEY (id, name)
);@dataclass
class Material:
id: int
name: str
edited: bool = false
deleted: bool = trueIf you like a can present a possible fix. In the from_ddl.py and prepare_data function I would change the bool.
Metadata
Metadata
Assignees
Labels
No labels