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
As per the paper and the design principle, ExperimentalData, Engines, Params and Monitor must be immutable. However, python doesn't allow this by default. I recommend some refactoring to the base classes to use the python dataclasses library by specifying a decorator @dataclass(frozen=True). This would enforce immutability and also avoid potential bugs and might simplify fixing them in the long-run.
The text was updated successfully, but these errors were encountered:
ShantanuKodgirwar
changed the title
Enforce immutability with package dataclasses
Enforce immutability with dataclassesAug 30, 2024
As per the paper and the design principle,
ExperimentalData
,Engines
,Params
andMonitor
must be immutable. However, python doesn't allow this by default. I recommend some refactoring to the base classes to use the pythondataclasses
library by specifying a decorator@dataclass(frozen=True)
. This would enforce immutability and also avoid potential bugs and might simplify fixing them in the long-run.The text was updated successfully, but these errors were encountered: