chore: fix typing errors
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
from copy import deepcopy
|
from copy import deepcopy
|
||||||
from typing import Any
|
from typing import Any, cast
|
||||||
|
|
||||||
from typing_extensions import TypedDict
|
from typing_extensions import TypedDict
|
||||||
|
|
||||||
@@ -16,12 +16,15 @@ class BacktestResultType(TypedDict):
|
|||||||
|
|
||||||
|
|
||||||
def get_BacktestResultType_default() -> BacktestResultType:
|
def get_BacktestResultType_default() -> BacktestResultType:
|
||||||
return deepcopy(
|
return cast(
|
||||||
{
|
BacktestResultType,
|
||||||
"metadata": {},
|
deepcopy(
|
||||||
"strategy": {},
|
{
|
||||||
"strategy_comparison": [],
|
"metadata": {},
|
||||||
}
|
"strategy": {},
|
||||||
|
"strategy_comparison": [],
|
||||||
|
}
|
||||||
|
),
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -132,6 +132,7 @@ class IStrategy(ABC, HyperStrategyMixin):
|
|||||||
stake_currency: str
|
stake_currency: str
|
||||||
# container variable for strategy source code
|
# container variable for strategy source code
|
||||||
__source__: str = ""
|
__source__: str = ""
|
||||||
|
__file__: str = ""
|
||||||
|
|
||||||
# Definition of plot_config. See plotting documentation for more details.
|
# Definition of plot_config. See plotting documentation for more details.
|
||||||
plot_config: dict = {}
|
plot_config: dict = {}
|
||||||
|
|||||||
Reference in New Issue
Block a user