mirror of
https://github.com/OpenBB-finance/OpenBB.git
synced 2026-11-09 02:42:36 +00:00
CI listing quick fix (#6002)
* BIGGGG LINTING * fixing lints * fixing lints * black * very ruff * no export * fix hedge_view again * lints * platform lints * lints * black * black it @hjoaquim * fix some more linting --------- Co-authored-by: hjoaquim <h.joaquim@campus.fct.unl.pt>
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
"""REST API for the OpenBB Platform."""
|
||||
|
||||
import logging
|
||||
from contextlib import asynccontextmanager
|
||||
|
||||
@@ -75,9 +76,11 @@ app.add_middleware(
|
||||
)
|
||||
AppLoader.from_routers(
|
||||
app=app,
|
||||
routers=[AuthService().router, router_system, router_coverage, router_commands]
|
||||
if Env().DEV_MODE
|
||||
else [router_commands],
|
||||
routers=(
|
||||
[AuthService().router, router_system, router_coverage, router_commands]
|
||||
if Env().DEV_MODE
|
||||
else [router_commands]
|
||||
),
|
||||
prefix=system.api_settings.prefix,
|
||||
)
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Coverage API router."""
|
||||
|
||||
from fastapi import APIRouter, Depends
|
||||
from openbb_core.api.dependency.coverage import get_command_map, get_provider_interface
|
||||
from openbb_core.app.provider_interface import ProviderInterface
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Coverage API router helper functions."""
|
||||
|
||||
from inspect import _empty, signature
|
||||
from typing import TYPE_CHECKING, Any, Callable, Dict, Optional, Tuple, Type
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""System router."""
|
||||
|
||||
from fastapi import APIRouter, Depends
|
||||
from openbb_core.api.dependency.system import get_system_settings
|
||||
from openbb_core.app.model.system_settings import SystemSettings
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Charting service."""
|
||||
|
||||
from importlib import import_module
|
||||
from inspect import getmembers, getsource, isfunction
|
||||
from typing import Callable, List, Optional, Tuple, TypeVar
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Command runner module."""
|
||||
|
||||
import warnings
|
||||
from contextlib import nullcontext
|
||||
from copy import deepcopy
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Constants for the OpenBB Platform."""
|
||||
|
||||
from pathlib import Path
|
||||
|
||||
HOME_DIRECTORY = Path.home()
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Posthog Handler."""
|
||||
|
||||
import json
|
||||
import logging
|
||||
import re
|
||||
|
||||
@@ -150,9 +150,11 @@ class LoggingService(metaclass=SingletonMeta):
|
||||
undefined = "undefined"
|
||||
|
||||
return {
|
||||
c: CredentialsDefinition.defined.value
|
||||
if credentials[c]
|
||||
else CredentialsDefinition.undefined.value
|
||||
c: (
|
||||
CredentialsDefinition.defined.value
|
||||
if credentials[c]
|
||||
else CredentialsDefinition.undefined.value
|
||||
)
|
||||
for c in credentials
|
||||
}
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Credentials model and its utilities."""
|
||||
|
||||
import traceback
|
||||
import warnings
|
||||
from typing import Dict, Optional, Set, Tuple
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Extension class for OBBject extensions."""
|
||||
|
||||
import warnings
|
||||
from typing import Callable, List, Optional
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""FastAPI configuration settings model."""
|
||||
|
||||
from typing import Dict, List, Optional
|
||||
|
||||
from pydantic import BaseModel, ConfigDict, Field, computed_field
|
||||
|
||||
@@ -71,9 +71,11 @@ class Metadata(BaseModel):
|
||||
type(arg_val[0]), pd.DataFrame
|
||||
):
|
||||
columns = [
|
||||
list(df.index.names) + df.columns.tolist()
|
||||
if any(index is not None for index in list(df.index.names))
|
||||
else df.columns.tolist()
|
||||
(
|
||||
list(df.index.names) + df.columns.tolist()
|
||||
if any(index is not None for index in list(df.index.names))
|
||||
else df.columns.tolist()
|
||||
)
|
||||
for df in arg_val
|
||||
]
|
||||
new_arg_val = {
|
||||
@@ -91,9 +93,11 @@ class Metadata(BaseModel):
|
||||
# List[Series]
|
||||
elif isinstance(arg_val, list) and isinstance(arg_val[0], pd.Series):
|
||||
columns = [
|
||||
list(series.index.names) + [series.name]
|
||||
if any(index is not None for index in list(series.index.names))
|
||||
else series.name
|
||||
(
|
||||
list(series.index.names) + [series.name]
|
||||
if any(index is not None for index in list(series.index.names))
|
||||
else series.name
|
||||
)
|
||||
for series in arg_val
|
||||
]
|
||||
new_arg_val = {
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""The OBBject."""
|
||||
|
||||
from re import sub
|
||||
from typing import (
|
||||
TYPE_CHECKING,
|
||||
|
||||
@@ -20,9 +20,9 @@ class Preferences(BaseModel):
|
||||
table_style: Literal["dark", "light"] = "dark"
|
||||
request_timeout: PositiveInt = 15
|
||||
metadata: bool = True
|
||||
output_type: Literal[
|
||||
"OBBject", "dataframe", "polars", "numpy", "dict", "chart"
|
||||
] = Field(default="OBBject", description="Python default output type.")
|
||||
output_type: Literal["OBBject", "dataframe", "polars", "numpy", "dict", "chart"] = (
|
||||
Field(default="OBBject", description="Python default output type.")
|
||||
)
|
||||
|
||||
model_config = ConfigDict(validate_assignment=True)
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""The OpenBB Platform System Settings."""
|
||||
|
||||
import json
|
||||
import platform as pl # I do this so that the import doesn't conflict with the variable name
|
||||
from pathlib import Path
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""User settings model."""
|
||||
|
||||
from pydantic import Field
|
||||
|
||||
from openbb_core.app.model.abstract.tagged import Tagged
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Provider Interface."""
|
||||
|
||||
from dataclasses import dataclass, make_dataclass
|
||||
from difflib import SequenceMatcher
|
||||
from typing import Any, Callable, Dict, List, Literal, Optional, Tuple, Type, Union
|
||||
@@ -252,12 +253,14 @@ class ProviderInterface(metaclass=SingletonMeta):
|
||||
default=default or None,
|
||||
title=provider_name,
|
||||
description=description,
|
||||
validation_alias=AliasChoices(
|
||||
field.alias,
|
||||
*list(set(alias_dict.get(name, []))),
|
||||
)
|
||||
if alias_dict.get(name, [])
|
||||
else None,
|
||||
validation_alias=(
|
||||
AliasChoices(
|
||||
field.alias,
|
||||
*list(set(alias_dict.get(name, []))),
|
||||
)
|
||||
if alias_dict.get(name, [])
|
||||
else None
|
||||
),
|
||||
json_schema_extra=field.json_schema_extra,
|
||||
)
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""OpenBB Router."""
|
||||
|
||||
import traceback
|
||||
import warnings
|
||||
from functools import lru_cache, partial
|
||||
@@ -275,9 +276,9 @@ class Router:
|
||||
if deprecation_message:
|
||||
kwargs["summary"] = deprecation_message
|
||||
else:
|
||||
kwargs[
|
||||
"summary"
|
||||
] = "This functionality will be deprecated in the future releases."
|
||||
kwargs["summary"] = (
|
||||
"This functionality will be deprecated in the future releases."
|
||||
)
|
||||
|
||||
api_router.add_api_route(**kwargs)
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Auth service."""
|
||||
|
||||
import logging
|
||||
from importlib import import_module
|
||||
from types import ModuleType
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Hub manager class."""
|
||||
|
||||
from typing import Optional
|
||||
|
||||
from fastapi import HTTPException
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""User service."""
|
||||
|
||||
import json
|
||||
from functools import reduce
|
||||
from pathlib import Path
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Account."""
|
||||
|
||||
# pylint: disable=W0212:protected-access
|
||||
import json
|
||||
from functools import wraps
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""App factory."""
|
||||
|
||||
from typing import Optional, Type, TypeVar
|
||||
|
||||
from openbb_core.app.command_runner import CommandRunner
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Container class."""
|
||||
|
||||
from typing import Any
|
||||
|
||||
from openbb_core.app.command_runner import CommandRunner
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Coverage module."""
|
||||
|
||||
from typing import TYPE_CHECKING, Any, Dict, List, Optional
|
||||
|
||||
from openbb_core.api.router.helpers.coverage_helpers import get_route_schema_map
|
||||
@@ -44,10 +45,8 @@ class Coverage:
|
||||
def command_model(self) -> Dict[str, Dict[str, Dict[str, Dict[str, Any]]]]:
|
||||
"""Return command to model mapping."""
|
||||
return {
|
||||
command: self._provider_interface.map[
|
||||
self._command_map.commands_model[command]
|
||||
]
|
||||
for command in self._command_map.commands_model
|
||||
command: self._provider_interface.map[value]
|
||||
for command, value in self._command_map.commands_model.items()
|
||||
}
|
||||
|
||||
def command_schemas(self, filter_by_provider: Optional[str] = None):
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Package Builder Class."""
|
||||
|
||||
# pylint: disable=too-many-lines
|
||||
import builtins
|
||||
import inspect
|
||||
@@ -383,9 +384,11 @@ class ClassDefinition:
|
||||
methods += MethodDefinition.build_command_method(
|
||||
path=route.path,
|
||||
func=route.endpoint,
|
||||
model_name=route.openapi_extra.get("model", None)
|
||||
if route.openapi_extra
|
||||
else None,
|
||||
model_name=(
|
||||
route.openapi_extra.get("model", None)
|
||||
if route.openapi_extra
|
||||
else None
|
||||
),
|
||||
) # type: ignore
|
||||
else:
|
||||
doc += " /" if path else " /"
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Console module."""
|
||||
|
||||
from openbb_core.env import Env
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Decorators for the OpenBB Platform static assets."""
|
||||
|
||||
from functools import wraps
|
||||
from typing import Any, Callable, Optional, TypeVar, overload
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""OpenBB filters."""
|
||||
|
||||
|
||||
from openbb_core.app.utils import convert_to_basemodel
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Linters for the package."""
|
||||
|
||||
import shutil
|
||||
import subprocess
|
||||
from pathlib import Path
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Version script for the OpenBB Platform."""
|
||||
|
||||
import shutil
|
||||
import subprocess
|
||||
from pathlib import Path
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
"""OpenBB Provider Package."""
|
||||
|
||||
from . import query_executor, registry, registry_map, standard_models # noqa: F401
|
||||
from .utils import descriptions, helpers # noqa: F401
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Abstract class for the fetcher."""
|
||||
|
||||
# ruff: noqa: S101
|
||||
# pylint: disable=E1101
|
||||
|
||||
@@ -59,9 +60,9 @@ class Fetcher(Generic[Q, R]):
|
||||
"""Transform the provider-specific data."""
|
||||
raise NotImplementedError
|
||||
|
||||
def __init_subclass__(cls, **kwargs):
|
||||
def __init_subclass__(cls, *args, **kwargs):
|
||||
"""Initialize the subclass."""
|
||||
super().__init_subclass__(**kwargs)
|
||||
super().__init_subclass__(*args, **kwargs)
|
||||
|
||||
if cls.aextract_data != Fetcher.aextract_data:
|
||||
cls.extract_data = cls.aextract_data
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""The OpenBB Standardized QueryParams Model that holds the query input parameters."""
|
||||
|
||||
from typing import Dict
|
||||
|
||||
from pydantic import BaseModel, ConfigDict
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Query executor module."""
|
||||
|
||||
from typing import Any, Dict, Optional, Type
|
||||
|
||||
from pydantic import SecretStr
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""AMERIBOR Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Optional
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Analyst Estimates Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import List, Literal, Set, Union
|
||||
|
||||
@@ -24,6 +23,7 @@ class AnalystEstimatesQueryParams(QueryParams):
|
||||
limit: int = Field(default=30, description=QUERY_DESCRIPTIONS.get("limit", ""))
|
||||
|
||||
@field_validator("symbol", mode="before", check_fields=False)
|
||||
@classmethod
|
||||
def upper_symbol(cls, v: Union[str, List[str], Set[str]]):
|
||||
"""Convert symbol to uppercase."""
|
||||
if isinstance(v, str):
|
||||
@@ -72,6 +72,7 @@ class AnalystEstimatesData(Data):
|
||||
)
|
||||
|
||||
@field_validator("symbol", mode="before", check_fields=False)
|
||||
@classmethod
|
||||
def upper_symbol(cls, v: Union[str, List[str], Set[str]]):
|
||||
"""Convert symbol to uppercase."""
|
||||
if isinstance(v, str):
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Available Indices Standard Model."""
|
||||
|
||||
|
||||
from typing import Optional
|
||||
|
||||
from pydantic import Field
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Balance Sheet Statement Growth Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import List, Optional, Set, Union
|
||||
|
||||
@@ -21,6 +20,7 @@ class BalanceSheetGrowthQueryParams(QueryParams):
|
||||
limit: int = Field(default=10, description=QUERY_DESCRIPTIONS.get("limit", ""))
|
||||
|
||||
@field_validator("symbol", mode="before", check_fields=False)
|
||||
@classmethod
|
||||
def upper_symbol(cls, v: Union[str, List[str], Set[str]]):
|
||||
"""Convert symbol to uppercase."""
|
||||
if isinstance(v, str):
|
||||
@@ -131,6 +131,7 @@ class BalanceSheetGrowthData(Data):
|
||||
growth_net_debt: float = Field(description="Growth rate of net debt.")
|
||||
|
||||
@field_validator("symbol", mode="before", check_fields=False)
|
||||
@classmethod
|
||||
def upper_symbol(cls, v: Union[str, List[str], Set[str]]):
|
||||
"""Convert symbol to uppercase."""
|
||||
if isinstance(v, str):
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Dividend Calendar Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Optional
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Earnings Calendar Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Optional
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Calendar Splits Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Optional
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Cash Flow Statement Growth Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import List, Optional, Set, Union
|
||||
|
||||
@@ -21,6 +20,7 @@ class CashFlowStatementGrowthQueryParams(QueryParams):
|
||||
limit: int = Field(default=10, description=QUERY_DESCRIPTIONS.get("limit", ""))
|
||||
|
||||
@field_validator("symbol", mode="before", check_fields=False)
|
||||
@classmethod
|
||||
def upper_symbol(cls, v: Union[str, List[str], Set[str]]):
|
||||
"""Convert symbol to uppercase."""
|
||||
if isinstance(v, str):
|
||||
@@ -118,6 +118,7 @@ class CashFlowStatementGrowthData(Data):
|
||||
growth_free_cash_flow: float = Field(description="Growth rate of free cash flow.")
|
||||
|
||||
@field_validator("symbol", mode="before", check_fields=False)
|
||||
@classmethod
|
||||
def upper_symbol(cls, v: Union[str, List[str], Set[str]]):
|
||||
"""Convert symbol to uppercase."""
|
||||
if isinstance(v, str):
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Company News Standard Model."""
|
||||
|
||||
|
||||
from datetime import datetime
|
||||
from typing import Optional
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Company Overview Standard Model."""
|
||||
|
||||
|
||||
from datetime import date
|
||||
from typing import List, Optional, Set, Union
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Compare Groups Model."""
|
||||
|
||||
from typing import Optional
|
||||
|
||||
from pydantic import Field
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Commercial Paper Standard Model."""
|
||||
|
||||
from datetime import (
|
||||
date as dateType,
|
||||
)
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""CPI Standard Model."""
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import List, Literal, Optional
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Crypto Historical Price Standard Model."""
|
||||
|
||||
|
||||
from datetime import (
|
||||
date as dateType,
|
||||
datetime,
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Currency Historical Price Standard Model."""
|
||||
|
||||
|
||||
from datetime import (
|
||||
date as dateType,
|
||||
datetime,
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Currency Available Pairs Standard Model."""
|
||||
|
||||
|
||||
from pydantic import Field
|
||||
|
||||
from openbb_core.provider.abstract.data import Data
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Discount Window Primary Credit Rate Standard Model."""
|
||||
|
||||
from datetime import (
|
||||
date as dateType,
|
||||
)
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Earnings Call Transcript Standard Model."""
|
||||
|
||||
|
||||
from datetime import datetime
|
||||
from typing import List, Set, Union
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""European Central Bank Interest Rates Standard Model."""
|
||||
|
||||
from datetime import (
|
||||
date as dateType,
|
||||
)
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Economic Calendar Standard Model."""
|
||||
|
||||
|
||||
from datetime import (
|
||||
date as dateType,
|
||||
datetime,
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Equity Historical Price Standard Model."""
|
||||
|
||||
|
||||
from datetime import (
|
||||
date as dateType,
|
||||
datetime,
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Equity Ownership Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import List, Optional, Set, Union
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Equity Short Interest Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
|
||||
from pydantic import Field
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""ESG Risk Rating Standard Model."""
|
||||
|
||||
|
||||
from typing import List, Literal, Set, Union
|
||||
|
||||
from pydantic import Field, field_validator
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""ESG Score Standard Model."""
|
||||
|
||||
|
||||
from datetime import (
|
||||
date as dateType,
|
||||
datetime,
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""ESG Sector Standard Model."""
|
||||
|
||||
|
||||
from openbb_core.provider.abstract.data import Data
|
||||
from openbb_core.provider.abstract.query_params import QueryParams
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""ESTR Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Optional
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""ETF Holdings Performance Standard Model."""
|
||||
|
||||
from .recent_performance import (
|
||||
RecentPerformanceData,
|
||||
RecentPerformanceQueryParams,
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""ETF Performance Standard Model."""
|
||||
|
||||
from datetime import date as dateType
|
||||
|
||||
from pydantic import Field
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Euro Area Yield Curve Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Literal, Optional
|
||||
|
||||
@@ -17,11 +16,11 @@ class EUYieldCurveQueryParams(QueryParams):
|
||||
date: Optional[dateType] = Field(
|
||||
default=None, description=QUERY_DESCRIPTIONS.get("date", "")
|
||||
)
|
||||
yield_curve_type: Literal[
|
||||
"spot_rate", "instantaneous_forward", "par_yield"
|
||||
] = Field(
|
||||
default="spot_rate",
|
||||
description="The yield curve type.",
|
||||
yield_curve_type: Literal["spot_rate", "instantaneous_forward", "par_yield"] = (
|
||||
Field(
|
||||
default="spot_rate",
|
||||
description="The yield curve type.",
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Executive Compensation Standard Model."""
|
||||
|
||||
|
||||
from datetime import (
|
||||
date as dateType,
|
||||
datetime,
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""PROJECTION Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Optional
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""FED Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Optional
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Selected Treasury Constant Maturity Standard Model."""
|
||||
|
||||
from datetime import (
|
||||
date as dateType,
|
||||
)
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""FRED Series Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import List, Optional, Set, Union
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Futures Curve Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import List, Optional, Set, Union
|
||||
|
||||
@@ -24,6 +23,7 @@ class FuturesCurveQueryParams(QueryParams):
|
||||
)
|
||||
|
||||
@field_validator("symbol", mode="before", check_fields=False)
|
||||
@classmethod
|
||||
def upper_symbol(cls, v: Union[str, List[str], Set[str]]):
|
||||
"""Convert symbol to uppercase."""
|
||||
if isinstance(v, str):
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Futures Historical Price Standard Model."""
|
||||
|
||||
|
||||
from datetime import date, datetime
|
||||
from typing import List, Optional, Set, Union
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Forecast GDP Standard Model."""
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Literal, Optional
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Nominal GDP Standard Model."""
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Literal, Optional
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Real GDP Standard Model."""
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Literal, Optional
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Historical Dividends Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import List, Optional, Set, Union
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Historical EPS Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import List, Optional, Set, Union
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Historical Splits Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import List, Set, Union
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""High Quality Market Corporate Bond Standard Model."""
|
||||
|
||||
from datetime import (
|
||||
date as dateType,
|
||||
)
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""ICE BofA US Corporate Bond Indices Standard Model."""
|
||||
|
||||
from datetime import (
|
||||
date as dateType,
|
||||
)
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Income Statement Growth Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import List, Literal, Optional, Set, Union
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Index Constituents Standard Model."""
|
||||
|
||||
|
||||
from typing import List, Optional, Set, Union
|
||||
|
||||
from pydantic import Field, field_validator
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Institutional Ownership Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import List, Optional, Set, Union
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Money Measures Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Optional
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""OTC Aggregate Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
|
||||
from pydantic import Field
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Price Target Standard Model."""
|
||||
|
||||
|
||||
from datetime import datetime
|
||||
from typing import List, Optional, Set, Union
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Price Target Consensus Standard Model."""
|
||||
|
||||
|
||||
from typing import List, Optional, Set, Union
|
||||
|
||||
from pydantic import Field, field_validator
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Reported Financials."""
|
||||
|
||||
import warnings
|
||||
from datetime import date as dateType
|
||||
from typing import Optional
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Risk Premium Standard Model."""
|
||||
|
||||
|
||||
from typing import Optional
|
||||
|
||||
from pydantic import Field, NonNegativeFloat, PositiveFloat
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Sector News Standard Model."""
|
||||
|
||||
|
||||
from datetime import datetime
|
||||
from typing import Dict, List, Optional
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Share Statistics Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import List, Optional, Set, Union
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Short Volume Standard Model."""
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Optional
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""SOFR Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Optional
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""SONIA Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Optional
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Spot Rate Standard Model."""
|
||||
|
||||
from datetime import (
|
||||
date as dateType,
|
||||
)
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Selected Treasury Bill Standard Model."""
|
||||
|
||||
from datetime import (
|
||||
date as dateType,
|
||||
)
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"""Treasury Constant Maturity Model."""
|
||||
|
||||
from datetime import (
|
||||
date as dateType,
|
||||
)
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Trailing Dividend Yield Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Optional
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Treasury Prices Standard Model."""
|
||||
|
||||
|
||||
from datetime import date as dateType
|
||||
from typing import Optional
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user