Skip to content

Commit

Permalink
Use default factory for empty df
Browse files Browse the repository at this point in the history
  • Loading branch information
AndreWohnsland committed Jun 1, 2024
1 parent 83f13eb commit 81d6ad9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/datastore.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

@dataclass
class Store:
df: pd.DataFrame = pd.DataFrame()
df: pd.DataFrame = field(default_factory=pd.DataFrame)
daily_data: list[tuple[str, str]] = field(default_factory=list)
current_date: datetime.date = datetime.date.today()
# dict with key: (year, month) and value: (hash(raw_data), pd.DataFrame)
Expand Down

0 comments on commit 81d6ad9

Please sign in to comment.