Freeze option leg dataclass in order to allow for hashing
This commit is contained in:
parent
c94919916f
commit
c6f86b8fd1
@ -2,7 +2,7 @@ from dataclasses import dataclass
|
|||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
from typing import Literal
|
from typing import Literal
|
||||||
|
|
||||||
@dataclass
|
@dataclass(frozen=True)
|
||||||
class OptionLeg:
|
class OptionLeg:
|
||||||
symbol: str
|
symbol: str
|
||||||
expiration: datetime
|
expiration: datetime
|
||||||
|
Loading…
Reference in New Issue
Block a user