From f4f8149e9400ac974f3e182e68198bcda940c2f6 Mon Sep 17 00:00:00 2001 From: Danglewood <85772166+deeleeramone@users.noreply.github.com> Date: Thu, 5 Dec 2024 23:02:41 -0800 Subject: [PATCH 1/5] run ruff check --fix on openbb-core --- .../core/openbb_core/api/router/commands.py | 2 +- .../core/openbb_core/app/command_runner.py | 3 +-- .../core/openbb_core/app/extension_loader.py | 1 - .../openbb_core/app/model/command_context.py | 3 +-- .../core/openbb_core/app/model/credentials.py | 9 ++++----- .../core/openbb_core/app/model/defaults.py | 3 +-- .../core/openbb_core/app/model/metadata.py | 3 +-- .../core/openbb_core/app/model/obbject.py | 3 +-- .../core/openbb_core/app/model/profile.py | 3 +-- .../openbb_core/app/model/system_settings.py | 3 +-- .../openbb_core/app/model/user_settings.py | 3 +-- .../openbb_core/app/provider_interface.py | 11 +++++------ .../core/openbb_core/app/router.py | 7 +++---- .../openbb_core/app/static/package_builder.py | 19 +++++-------------- .../openbb_core/app/static/utils/linters.py | 4 ++-- openbb_platform/core/openbb_core/app/utils.py | 3 +-- .../core/openbb_core/app/version.py | 4 ++-- openbb_platform/core/openbb_core/env.py | 1 - .../openbb_core/provider/abstract/fetcher.py | 2 +- .../openbb_core/provider/query_executor.py | 3 +-- .../core/openbb_core/provider/registry_map.py | 3 +-- .../provider/standard_models/ameribor.py | 3 +-- .../standard_models/analyst_estimates.py | 3 +-- .../standard_models/analyst_search.py | 3 +-- .../standard_models/available_indicators.py | 3 +-- .../standard_models/available_indices.py | 3 +-- .../standard_models/balance_of_payments.py | 3 +-- .../provider/standard_models/balance_sheet.py | 3 +-- .../standard_models/balance_sheet_growth.py | 3 +-- .../provider/standard_models/bls_search.py | 3 +-- .../provider/standard_models/bls_series.py | 3 +-- .../provider/standard_models/bond_indices.py | 3 +-- .../provider/standard_models/bond_prices.py | 3 +-- .../standard_models/bond_reference.py | 3 +-- .../provider/standard_models/bond_trades.py | 3 +-- .../standard_models/calendar_dividend.py | 3 +-- .../standard_models/calendar_earnings.py | 3 +-- .../provider/standard_models/calendar_ipo.py | 3 +-- .../standard_models/calendar_splits.py | 3 +-- .../provider/standard_models/cash_flow.py | 3 +-- .../standard_models/cash_flow_growth.py | 3 +-- .../standard_models/central_bank_holdings.py | 3 +-- .../provider/standard_models/cik_map.py | 3 +-- .../standard_models/commercial_paper.py | 3 +-- .../standard_models/commodity_spot_prices.py | 3 +-- .../standard_models/company_filings.py | 3 +-- .../provider/standard_models/company_news.py | 3 +-- .../standard_models/company_overview.py | 3 +-- .../standard_models/compare_company_facts.py | 3 +-- .../standard_models/compare_groups.py | 3 +-- .../composite_leading_indicator.py | 3 +-- .../standard_models/consumer_price_index.py | 3 +-- .../provider/standard_models/cot.py | 3 +-- .../provider/standard_models/cot_search.py | 3 +-- .../standard_models/country_interest_rates.py | 3 +-- .../standard_models/country_profile.py | 3 +-- .../standard_models/crypto_historical.py | 3 +-- .../provider/standard_models/crypto_search.py | 3 +-- .../standard_models/currency_historical.py | 3 +-- .../standard_models/currency_pairs.py | 3 +-- .../currency_reference_rates.py | 3 +-- .../standard_models/currency_snapshots.py | 3 +-- .../standard_models/direction_of_trade.py | 3 +-- .../standard_models/discovery_filings.py | 3 +-- .../provider/standard_models/dwpcr_rates.py | 3 +-- .../earnings_call_transcript.py | 3 +-- .../standard_models/ecb_interest_rates.py | 3 +-- .../standard_models/economic_calendar.py | 3 +-- .../standard_models/economic_indicators.py | 3 +-- .../provider/standard_models/equity_ftd.py | 3 +-- .../standard_models/equity_historical.py | 3 +-- .../provider/standard_models/equity_info.py | 3 +-- .../provider/standard_models/equity_nbbo.py | 3 +-- .../standard_models/equity_ownership.py | 3 +-- .../provider/standard_models/equity_peers.py | 3 +-- .../standard_models/equity_performance.py | 3 +-- .../provider/standard_models/equity_quote.py | 3 +-- .../standard_models/equity_screener.py | 3 +-- .../provider/standard_models/equity_search.py | 3 +-- .../standard_models/equity_short_interest.py | 3 +-- .../equity_valuation_multiples.py | 3 +-- .../standard_models/esg_risk_rating.py | 3 +-- .../provider/standard_models/esg_score.py | 3 +-- .../provider/standard_models/etf_countries.py | 3 +-- .../standard_models/etf_equity_exposure.py | 3 +-- .../standard_models/etf_historical.py | 3 +-- .../standard_models/etf_historical_nav.py | 3 +-- .../provider/standard_models/etf_holdings.py | 3 +-- .../standard_models/etf_holdings_date.py | 3 +-- .../provider/standard_models/etf_info.py | 3 +-- .../standard_models/etf_performance.py | 3 +-- .../provider/standard_models/etf_search.py | 3 +-- .../provider/standard_models/etf_sectors.py | 3 +-- .../standard_models/eu_yield_curve.py | 3 +-- .../standard_models/euro_short_term_rate.py | 3 +-- .../standard_models/executive_compensation.py | 3 +-- .../standard_models/export_destinations.py | 3 +-- .../standard_models/fed_projections.py | 3 +-- .../standard_models/federal_funds_rate.py | 3 +-- .../provider/standard_models/ffrmc.py | 3 +-- .../standard_models/financial_attributes.py | 3 +-- .../standard_models/financial_ratios.py | 3 +-- .../forward_ebitda_estimates.py | 3 +-- .../standard_models/forward_eps_estimates.py | 3 +-- .../standard_models/forward_pe_estimates.py | 3 +-- .../forward_sales_estimates.py | 3 +-- .../standard_models/fred_release_table.py | 3 +-- .../provider/standard_models/fred_search.py | 3 +-- .../provider/standard_models/fred_series.py | 3 +-- .../provider/standard_models/futures_curve.py | 3 +-- .../standard_models/futures_historical.py | 3 +-- .../provider/standard_models/gdp_forecast.py | 3 +-- .../provider/standard_models/gdp_nominal.py | 3 +-- .../provider/standard_models/gdp_real.py | 3 +-- .../standard_models/high_quality_market.py | 3 +-- .../standard_models/historical_attributes.py | 3 +-- .../standard_models/historical_dividends.py | 3 +-- .../standard_models/historical_employees.py | 3 +-- .../standard_models/historical_eps.py | 3 +-- .../standard_models/historical_market_cap.py | 3 +-- .../standard_models/historical_splits.py | 3 +-- .../standard_models/house_price_index.py | 3 +-- .../provider/standard_models/ice_bofa.py | 3 +-- .../immediate_interest_rate.py | 3 +-- .../standard_models/income_statement.py | 3 +-- .../income_statement_growth.py | 3 +-- .../standard_models/index_historical.py | 3 +-- .../provider/standard_models/index_info.py | 3 +-- .../provider/standard_models/index_search.py | 3 +-- .../provider/standard_models/index_sectors.py | 3 +-- .../standard_models/index_snapshots.py | 3 +-- .../provider/standard_models/industry_pe.py | 3 +-- .../standard_models/insider_trading.py | 3 +-- .../institutional_ownership.py | 3 +-- .../provider/standard_models/iorb_rates.py | 3 +-- .../standard_models/key_executives.py | 3 +-- .../provider/standard_models/key_metrics.py | 3 +-- .../standard_models/latest_attributes.py | 3 +-- .../provider/standard_models/lbma_fixing.py | 3 +-- .../long_term_interest_rate.py | 3 +-- .../manufacturing_outlook_texas.py | 3 +-- .../provider/standard_models/market_movers.py | 3 +-- .../standard_models/market_snapshots.py | 3 +-- .../standard_models/money_measures.py | 3 +-- .../provider/standard_models/moody.py | 3 +-- .../standard_models/mortgage_indices.py | 3 +-- .../standard_models/non_farm_payrolls.py | 3 +-- .../standard_models/options_chains.py | 3 +-- .../standard_models/options_snapshots.py | 3 +-- .../standard_models/options_unusual.py | 3 +-- .../provider/standard_models/otc_aggregate.py | 3 +-- .../overnight_bank_funding_rate.py | 3 +-- .../personal_consumption_expenditures.py | 3 +-- .../petroleum_status_report.py | 3 +-- .../provider/standard_models/port_volume.py | 3 +-- .../provider/standard_models/price_target.py | 3 +-- .../standard_models/price_target_consensus.py | 3 +-- .../standard_models/primary_dealer_fails.py | 3 +-- .../primary_dealer_positioning.py | 3 +-- .../standard_models/recent_performance.py | 3 +-- .../standard_models/reported_financials.py | 3 +-- .../provider/standard_models/retail_prices.py | 3 +-- .../standard_models/revenue_business_line.py | 3 +-- .../standard_models/revenue_geographic.py | 3 +-- .../provider/standard_models/risk_premium.py | 3 +-- .../standard_models/search_attributes.py | 3 +-- .../search_financial_attributes.py | 3 +-- .../provider/standard_models/sector_pe.py | 3 +-- .../standard_models/sector_performance.py | 3 +-- .../senior_loan_officer_survey.py | 3 +-- .../standard_models/share_price_index.py | 3 +-- .../standard_models/share_statistics.py | 3 +-- .../short_term_energy_outlook.py | 3 +-- .../short_term_interest_rate.py | 3 +-- .../provider/standard_models/short_volume.py | 3 +-- .../provider/standard_models/sofr.py | 3 +-- .../provider/standard_models/sonia_rates.py | 3 +-- .../standard_models/sp500_multiples.py | 3 +-- .../provider/standard_models/spot.py | 3 +-- .../survey_of_economic_conditions_chicago.py | 3 +-- .../provider/standard_models/symbol_map.py | 3 +-- .../provider/standard_models/tbffr.py | 3 +-- .../provider/standard_models/tips_yields.py | 3 +-- .../provider/standard_models/tmc.py | 3 +-- .../provider/standard_models/top_retail.py | 3 +-- .../trailing_dividend_yield.py | 3 +-- .../standard_models/treasury_auctions.py | 3 +-- .../standard_models/treasury_prices.py | 3 +-- .../standard_models/treasury_rates.py | 3 +-- .../provider/standard_models/unemployment.py | 3 +-- .../standard_models/university_of_michigan.py | 3 +-- .../standard_models/us_yield_curve.py | 3 +-- .../provider/standard_models/world_news.py | 3 +-- .../openbb_core/provider/utils/helpers.py | 3 +-- .../core/tests/app/static/test_container.py | 3 ++- .../tests/app/static/test_package_builder.py | 2 +- 196 files changed, 210 insertions(+), 407 deletions(-) diff --git a/openbb_platform/core/openbb_core/api/router/commands.py b/openbb_platform/core/openbb_core/api/router/commands.py index a4f68a14bead..dc029220a074 100644 --- a/openbb_platform/core/openbb_core/api/router/commands.py +++ b/openbb_platform/core/openbb_core/api/router/commands.py @@ -204,7 +204,7 @@ async def wrapper(*args: Tuple[Any], **kwargs: Dict[str, Any]) -> OBBject: if defaults: provider_choices = getattr( - kwargs.get("provider_choices", None), "__dict__", {} + kwargs.get("provider_choices"), "__dict__", {} ) _provider = defaults.pop("provider", None) diff --git a/openbb_platform/core/openbb_core/app/command_runner.py b/openbb_platform/core/openbb_core/app/command_runner.py index d04383089389..9d83f9a2df03 100644 --- a/openbb_platform/core/openbb_core/app/command_runner.py +++ b/openbb_platform/core/openbb_core/app/command_runner.py @@ -11,8 +11,6 @@ from typing import TYPE_CHECKING, Any, Callable, Dict, List, Optional, Tuple, Type from warnings import catch_warnings, showwarning, warn -from pydantic import BaseModel, ConfigDict, create_model - from openbb_core.app.model.abstract.error import OpenBBError from openbb_core.app.model.abstract.warning import OpenBBWarning, cast_warning from openbb_core.app.model.metadata import Metadata @@ -20,6 +18,7 @@ from openbb_core.app.provider_interface import ExtraParams from openbb_core.env import Env from openbb_core.provider.utils.helpers import maybe_coroutine, run_async +from pydantic import BaseModel, ConfigDict, create_model if TYPE_CHECKING: from openbb_core.app.model.system_settings import SystemSettings diff --git a/openbb_platform/core/openbb_core/app/extension_loader.py b/openbb_platform/core/openbb_core/app/extension_loader.py index ea31e3cf7ca6..2b3bd3eac044 100644 --- a/openbb_platform/core/openbb_core/app/extension_loader.py +++ b/openbb_platform/core/openbb_core/app/extension_loader.py @@ -5,7 +5,6 @@ from typing import TYPE_CHECKING, Any, Dict, List, Optional from importlib_metadata import EntryPoint, EntryPoints, entry_points - from openbb_core.app.model.abstract.singleton import SingletonMeta from openbb_core.app.model.extension import Extension diff --git a/openbb_platform/core/openbb_core/app/model/command_context.py b/openbb_platform/core/openbb_core/app/model/command_context.py index 977df7a485b7..ede1aac4bd7e 100644 --- a/openbb_platform/core/openbb_core/app/model/command_context.py +++ b/openbb_platform/core/openbb_core/app/model/command_context.py @@ -1,9 +1,8 @@ """Command Context.""" -from pydantic import BaseModel, Field - from openbb_core.app.model.system_settings import SystemSettings from openbb_core.app.model.user_settings import UserSettings +from pydantic import BaseModel, Field class CommandContext(BaseModel): diff --git a/openbb_platform/core/openbb_core/app/model/credentials.py b/openbb_platform/core/openbb_core/app/model/credentials.py index 457accd7b706..5f5c594825fc 100644 --- a/openbb_platform/core/openbb_core/app/model/credentials.py +++ b/openbb_platform/core/openbb_core/app/model/credentials.py @@ -4,6 +4,10 @@ import warnings from typing import Dict, List, Optional, Tuple +from openbb_core.app.extension_loader import ExtensionLoader +from openbb_core.app.model.abstract.warning import OpenBBWarning +from openbb_core.app.provider_interface import ProviderInterface +from openbb_core.env import Env from pydantic import ( BaseModel, ConfigDict, @@ -14,11 +18,6 @@ from pydantic.functional_serializers import PlainSerializer from typing_extensions import Annotated -from openbb_core.app.extension_loader import ExtensionLoader -from openbb_core.app.model.abstract.warning import OpenBBWarning -from openbb_core.app.provider_interface import ProviderInterface -from openbb_core.env import Env - class LoadingError(Exception): """Error loading extension.""" diff --git a/openbb_platform/core/openbb_core/app/model/defaults.py b/openbb_platform/core/openbb_core/app/model/defaults.py index 3b283753eea5..a5a0d11bfaf6 100644 --- a/openbb_platform/core/openbb_core/app/model/defaults.py +++ b/openbb_platform/core/openbb_core/app/model/defaults.py @@ -3,9 +3,8 @@ from typing import Any from warnings import warn -from pydantic import BaseModel, ConfigDict, Field, model_validator - from openbb_core.app.model.abstract.warning import OpenBBWarning +from pydantic import BaseModel, ConfigDict, Field, model_validator class Defaults(BaseModel): diff --git a/openbb_platform/core/openbb_core/app/model/metadata.py b/openbb_platform/core/openbb_core/app/model/metadata.py index f3cabea2e649..a8d660f0d91e 100644 --- a/openbb_platform/core/openbb_core/app/model/metadata.py +++ b/openbb_platform/core/openbb_core/app/model/metadata.py @@ -3,9 +3,8 @@ from datetime import datetime from typing import Any, Dict, Optional, Sequence, Union -from pydantic import BaseModel, Field, field_validator - from openbb_core.provider.abstract.data import Data +from pydantic import BaseModel, Field, field_validator class Metadata(BaseModel): diff --git a/openbb_platform/core/openbb_core/app/model/obbject.py b/openbb_platform/core/openbb_core/app/model/obbject.py index 2b10fac38cba..191ee3efaf4a 100644 --- a/openbb_platform/core/openbb_core/app/model/obbject.py +++ b/openbb_platform/core/openbb_core/app/model/obbject.py @@ -16,14 +16,13 @@ Union, ) -from pydantic import BaseModel, Field, PrivateAttr - from openbb_core.app.model.abstract.error import OpenBBError from openbb_core.app.model.abstract.tagged import Tagged from openbb_core.app.model.abstract.warning import Warning_ from openbb_core.app.model.charts.chart import Chart from openbb_core.provider.abstract.annotated_result import AnnotatedResult from openbb_core.provider.abstract.data import Data +from pydantic import BaseModel, Field, PrivateAttr if TYPE_CHECKING: from numpy import ndarray # noqa diff --git a/openbb_platform/core/openbb_core/app/model/profile.py b/openbb_platform/core/openbb_core/app/model/profile.py index f1e62db03934..cf5d873bfc13 100644 --- a/openbb_platform/core/openbb_core/app/model/profile.py +++ b/openbb_platform/core/openbb_core/app/model/profile.py @@ -2,9 +2,8 @@ from typing import Optional -from pydantic import BaseModel, ConfigDict, Field - from openbb_core.app.model.hub.hub_session import HubSession +from pydantic import BaseModel, ConfigDict, Field class Profile(BaseModel): diff --git a/openbb_platform/core/openbb_core/app/model/system_settings.py b/openbb_platform/core/openbb_core/app/model/system_settings.py index 0f9856962437..29d3201f8407 100644 --- a/openbb_platform/core/openbb_core/app/model/system_settings.py +++ b/openbb_platform/core/openbb_core/app/model/system_settings.py @@ -5,8 +5,6 @@ from pathlib import Path from typing import List, Literal, Optional -from pydantic import ConfigDict, Field, field_validator, model_validator - from openbb_core.app.constants import ( HOME_DIRECTORY, OPENBB_DIRECTORY, @@ -17,6 +15,7 @@ from openbb_core.app.model.api_settings import APISettings from openbb_core.app.model.python_settings import PythonSettings from openbb_core.app.version import CORE_VERSION, VERSION +from pydantic import ConfigDict, Field, field_validator, model_validator class SystemSettings(Tagged): diff --git a/openbb_platform/core/openbb_core/app/model/user_settings.py b/openbb_platform/core/openbb_core/app/model/user_settings.py index ea3ada125413..28622eae919d 100644 --- a/openbb_platform/core/openbb_core/app/model/user_settings.py +++ b/openbb_platform/core/openbb_core/app/model/user_settings.py @@ -1,12 +1,11 @@ """User settings model.""" -from pydantic import Field - from openbb_core.app.model.abstract.tagged import Tagged from openbb_core.app.model.credentials import Credentials from openbb_core.app.model.defaults import Defaults from openbb_core.app.model.preferences import Preferences from openbb_core.app.model.profile import Profile +from pydantic import Field class UserSettings(Tagged): diff --git a/openbb_platform/core/openbb_core/app/provider_interface.py b/openbb_platform/core/openbb_core/app/provider_interface.py index 901e47ec21e2..03d63981d2e0 100644 --- a/openbb_platform/core/openbb_core/app/provider_interface.py +++ b/openbb_platform/core/openbb_core/app/provider_interface.py @@ -16,6 +16,11 @@ ) from fastapi import Body, Query +from openbb_core.app.model.abstract.singleton import SingletonMeta +from openbb_core.app.model.obbject import OBBject +from openbb_core.provider.query_executor import QueryExecutor +from openbb_core.provider.registry_map import MapType, RegistryMap +from openbb_core.provider.utils.helpers import to_snake_case from pydantic import ( BaseModel, ConfigDict, @@ -27,12 +32,6 @@ ) from pydantic.fields import FieldInfo -from openbb_core.app.model.abstract.singleton import SingletonMeta -from openbb_core.app.model.obbject import OBBject -from openbb_core.provider.query_executor import QueryExecutor -from openbb_core.provider.registry_map import MapType, RegistryMap -from openbb_core.provider.utils.helpers import to_snake_case - TupleFieldType = Tuple[str, Optional[Type], Optional[Any]] diff --git a/openbb_platform/core/openbb_core/app/router.py b/openbb_platform/core/openbb_core/app/router.py index 7f3ab8f98700..72c2e3751756 100644 --- a/openbb_platform/core/openbb_core/app/router.py +++ b/openbb_platform/core/openbb_core/app/router.py @@ -19,10 +19,6 @@ ) from fastapi import APIRouter, Depends -from pydantic import BaseModel -from pydantic.v1.validators import find_validators -from typing_extensions import Annotated, ParamSpec, _AnnotatedAlias - from openbb_core.app.deprecation import DeprecationSummary, OpenBBDeprecationWarning from openbb_core.app.extension_loader import ExtensionLoader from openbb_core.app.model.abstract.warning import OpenBBWarning @@ -35,6 +31,9 @@ StandardParams, ) from openbb_core.env import Env +from pydantic import BaseModel +from pydantic.v1.validators import find_validators +from typing_extensions import Annotated, ParamSpec, _AnnotatedAlias P = ParamSpec("P") diff --git a/openbb_platform/core/openbb_core/app/static/package_builder.py b/openbb_platform/core/openbb_core/app/static/package_builder.py index ceabbcf7fa0c..67892977bd18 100644 --- a/openbb_platform/core/openbb_core/app/static/package_builder.py +++ b/openbb_platform/core/openbb_core/app/static/package_builder.py @@ -5,7 +5,6 @@ import inspect import re import shutil -import sys from dataclasses import Field as DCField from functools import partial from inspect import Parameter, _empty, isclass, signature @@ -31,11 +30,6 @@ ) from importlib_metadata import entry_points -from pydantic.fields import FieldInfo -from pydantic_core import PydanticUndefined -from starlette.routing import BaseRoute -from typing_extensions import Annotated, _AnnotatedAlias - from openbb_core.app.extension_loader import ExtensionLoader, OpenBBGroups from openbb_core.app.model.example import Example from openbb_core.app.model.field import OpenBBField @@ -47,6 +41,10 @@ from openbb_core.app.static.utils.linters import Linters from openbb_core.app.version import CORE_VERSION, VERSION from openbb_core.env import Env +from pydantic.fields import FieldInfo +from pydantic_core import PydanticUndefined +from starlette.routing import BaseRoute +from typing_extensions import Annotated, _AnnotatedAlias if TYPE_CHECKING: # pylint: disable=import-outside-toplevel @@ -377,18 +375,11 @@ def build(cls, path: str) -> str: code += "\nfrom typing import TYPE_CHECKING, ForwardRef, List, Dict, Union, Optional, Literal, Any" code += "\nfrom annotated_types import Ge, Le, Gt, Lt" code += "\nfrom warnings import warn, simplefilter" - if sys.version_info < (3, 9): - code += "\nimport typing_extensions" - else: - code += "\nfrom typing_extensions import Annotated, deprecated" - # code += "\nfrom openbb_core.app.utils import df_to_basemodel" + code += "\nfrom typing_extensions import Annotated, deprecated" code += "\nfrom openbb_core.app.static.utils.decorators import exception_handler, validate\n" code += "\nfrom openbb_core.app.static.utils.filters import filter_inputs\n" code += "\nfrom openbb_core.app.deprecation import OpenBBDeprecationWarning\n" code += "\nfrom openbb_core.app.model.field import OpenBBField" - # if path.startswith("/quantitative"): - # code += "\nfrom openbb_quantitative.models import " - # code += "(CAPMModel,NormalityModel,OmegaModel,SummaryModel,UnitRootModel)" module_list = [hint_type.__module__ for hint_type in hint_type_list] module_list = list(set(module_list)) module_list.sort() diff --git a/openbb_platform/core/openbb_core/app/static/utils/linters.py b/openbb_platform/core/openbb_core/app/static/utils/linters.py index d22cf3061695..8ee234db5b3c 100644 --- a/openbb_platform/core/openbb_core/app/static/utils/linters.py +++ b/openbb_platform/core/openbb_core/app/static/utils/linters.py @@ -39,8 +39,8 @@ def run( command = [linter] if flags: command.extend(flags) # type: ignore - subprocess.run( - command + list(self.directory.glob("*.py")), check=False # noqa: S603 + subprocess.run( # noqa: S603 + command + list(self.directory.glob("*.py")), check=False ) self.print_separator("-") diff --git a/openbb_platform/core/openbb_core/app/utils.py b/openbb_platform/core/openbb_core/app/utils.py index c9b5327f8010..4a46b30dd584 100644 --- a/openbb_platform/core/openbb_core/app/utils.py +++ b/openbb_platform/core/openbb_core/app/utils.py @@ -5,12 +5,11 @@ from datetime import time from typing import TYPE_CHECKING, Dict, List, Optional, Union -from pydantic import ValidationError - from openbb_core.app.model.abstract.error import OpenBBError from openbb_core.app.model.preferences import Preferences from openbb_core.app.model.system_settings import SystemSettings from openbb_core.provider.abstract.data import Data +from pydantic import ValidationError if TYPE_CHECKING: # pylint: disable=import-outside-toplevel diff --git a/openbb_platform/core/openbb_core/app/version.py b/openbb_platform/core/openbb_core/app/version.py index 1fecec6f3bb3..84bf3f555598 100644 --- a/openbb_platform/core/openbb_core/app/version.py +++ b/openbb_platform/core/openbb_core/app/version.py @@ -40,8 +40,8 @@ def is_git_repo(path: Path): if not git_executable: return False try: - subprocess.run( - [git_executable, "rev-parse", "--is-inside-work-tree"], # noqa: S603 + subprocess.run( # noqa: S603 + [git_executable, "rev-parse", "--is-inside-work-tree"], cwd=path, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL, diff --git a/openbb_platform/core/openbb_core/env.py b/openbb_platform/core/openbb_core/env.py index 9249658ffbc8..afd03b9e3ad6 100644 --- a/openbb_platform/core/openbb_core/env.py +++ b/openbb_platform/core/openbb_core/env.py @@ -5,7 +5,6 @@ from typing import Dict, Optional import dotenv - from openbb_core.app.constants import OPENBB_DIRECTORY from openbb_core.app.model.abstract.singleton import SingletonMeta diff --git a/openbb_platform/core/openbb_core/provider/abstract/fetcher.py b/openbb_platform/core/openbb_core/provider/abstract/fetcher.py index 4fd40bb687ac..6cdf4f9d6d44 100644 --- a/openbb_platform/core/openbb_core/provider/abstract/fetcher.py +++ b/openbb_platform/core/openbb_core/provider/abstract/fetcher.py @@ -108,7 +108,7 @@ def data_type(self) -> D: # type: ignore @staticmethod def _get_data_type(data: Any) -> D: # type: ignore """Get the type of the data.""" - if get_origin(data) == list: + if get_origin(data) is list: data = get_args(data)[0] return data diff --git a/openbb_platform/core/openbb_core/provider/query_executor.py b/openbb_platform/core/openbb_core/provider/query_executor.py index dd19503a6901..75a85df5363a 100644 --- a/openbb_platform/core/openbb_core/provider/query_executor.py +++ b/openbb_platform/core/openbb_core/provider/query_executor.py @@ -2,12 +2,11 @@ from typing import Any, Dict, Optional, Type -from pydantic import SecretStr - from openbb_core.app.model.abstract.error import OpenBBError from openbb_core.provider.abstract.fetcher import Fetcher from openbb_core.provider.abstract.provider import Provider from openbb_core.provider.registry import Registry, RegistryLoader +from pydantic import SecretStr class QueryExecutor: diff --git a/openbb_platform/core/openbb_core/provider/registry_map.py b/openbb_platform/core/openbb_core/provider/registry_map.py index c3ccdb1b6f68..e55b7f0b6565 100644 --- a/openbb_platform/core/openbb_core/provider/registry_map.py +++ b/openbb_platform/core/openbb_core/provider/registry_map.py @@ -5,12 +5,11 @@ from pathlib import Path from typing import Any, Dict, List, Literal, Optional, Tuple, get_origin -from pydantic import BaseModel - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.fetcher import Fetcher from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.registry import Registry, RegistryLoader +from pydantic import BaseModel MapType = Dict[str, Dict[str, Dict[str, Dict[str, Any]]]] diff --git a/openbb_platform/core/openbb_core/provider/standard_models/ameribor.py b/openbb_platform/core/openbb_core/provider/standard_models/ameribor.py index 2edf6f66b670..9eed2bf7d00d 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/ameribor.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/ameribor.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class AmeriborQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/analyst_estimates.py b/openbb_platform/core/openbb_core/provider/standard_models/analyst_estimates.py index 4e49cdbf98df..824b596835de 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/analyst_estimates.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/analyst_estimates.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data, ForceInt from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class AnalystEstimatesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/analyst_search.py b/openbb_platform/core/openbb_core/provider/standard_models/analyst_search.py index 14f95b00de53..27921d7e736e 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/analyst_search.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/analyst_search.py @@ -5,10 +5,9 @@ ) from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams +from pydantic import Field class AnalystSearchQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/available_indicators.py b/openbb_platform/core/openbb_core/provider/standard_models/available_indicators.py index 3e1167b1d82a..aa526a9b95d0 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/available_indicators.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/available_indicators.py @@ -2,11 +2,10 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class AvailableIndicesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/available_indices.py b/openbb_platform/core/openbb_core/provider/standard_models/available_indices.py index 5b192f4c4585..29e42709fdb7 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/available_indices.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/available_indices.py @@ -2,10 +2,9 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams +from pydantic import Field class AvailableIndicesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/balance_of_payments.py b/openbb_platform/core/openbb_core/provider/standard_models/balance_of_payments.py index d29198017141..16169746ac11 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/balance_of_payments.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/balance_of_payments.py @@ -5,10 +5,9 @@ ) from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams +from pydantic import Field class BalanceOfPaymentsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/balance_sheet.py b/openbb_platform/core/openbb_core/provider/standard_models/balance_sheet.py index c935d841b8cb..5ae5918bf445 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/balance_sheet.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/balance_sheet.py @@ -3,13 +3,12 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, NonNegativeInt, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( QUERY_DESCRIPTIONS, ) +from pydantic import Field, NonNegativeInt, field_validator class BalanceSheetQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/balance_sheet_growth.py b/openbb_platform/core/openbb_core/provider/standard_models/balance_sheet_growth.py index 0506e0ad2ccf..43a92ab87c9d 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/balance_sheet_growth.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/balance_sheet_growth.py @@ -3,11 +3,10 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field, field_validator class BalanceSheetGrowthQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/bls_search.py b/openbb_platform/core/openbb_core/provider/standard_models/bls_search.py index ce1183b4f56e..3bc4a23f315a 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/bls_search.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/bls_search.py @@ -2,11 +2,10 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class SearchQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/bls_series.py b/openbb_platform/core/openbb_core/provider/standard_models/bls_series.py index 1aeb7e40633e..fa48a9131c04 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/bls_series.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/bls_series.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class SeriesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/bond_indices.py b/openbb_platform/core/openbb_core/provider/standard_models/bond_indices.py index f778c3bb6c11..a48f0d572a47 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/bond_indices.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/bond_indices.py @@ -5,14 +5,13 @@ ) from typing import Literal, Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class BondIndicesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/bond_prices.py b/openbb_platform/core/openbb_core/provider/standard_models/bond_prices.py index e0e6dd5f71d1..5ec395aaa8a2 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/bond_prices.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/bond_prices.py @@ -5,10 +5,9 @@ ) from typing import List, Optional, Union -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams +from pydantic import Field class BondPricesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/bond_reference.py b/openbb_platform/core/openbb_core/provider/standard_models/bond_reference.py index 771be0921618..053fd46fad80 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/bond_reference.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/bond_reference.py @@ -5,10 +5,9 @@ ) from typing import List, Optional, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams +from pydantic import Field, field_validator class BondReferenceQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/bond_trades.py b/openbb_platform/core/openbb_core/provider/standard_models/bond_trades.py index ca6edf65e236..051c596ec327 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/bond_trades.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/bond_trades.py @@ -6,14 +6,13 @@ ) from typing import Literal, Optional, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class BondTradesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/calendar_dividend.py b/openbb_platform/core/openbb_core/provider/standard_models/calendar_dividend.py index 83790431c74e..136042e2fcfa 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/calendar_dividend.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/calendar_dividend.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class CalendarDividendQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/calendar_earnings.py b/openbb_platform/core/openbb_core/provider/standard_models/calendar_earnings.py index b87670ba7429..695295289320 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/calendar_earnings.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/calendar_earnings.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class CalendarEarningsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/calendar_ipo.py b/openbb_platform/core/openbb_core/provider/standard_models/calendar_ipo.py index 7d09136c4c90..f9498a90280d 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/calendar_ipo.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/calendar_ipo.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class CalendarIpoQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/calendar_splits.py b/openbb_platform/core/openbb_core/provider/standard_models/calendar_splits.py index c1869254c8a2..89077dd8540c 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/calendar_splits.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/calendar_splits.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class CalendarSplitsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/cash_flow.py b/openbb_platform/core/openbb_core/provider/standard_models/cash_flow.py index 938d4e63bae8..f2dc959606ce 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/cash_flow.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/cash_flow.py @@ -3,11 +3,10 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, NonNegativeInt, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field, NonNegativeInt, field_validator class CashFlowStatementQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/cash_flow_growth.py b/openbb_platform/core/openbb_core/provider/standard_models/cash_flow_growth.py index 79d07b520c26..895457850292 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/cash_flow_growth.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/cash_flow_growth.py @@ -3,11 +3,10 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field, field_validator class CashFlowStatementGrowthQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/central_bank_holdings.py b/openbb_platform/core/openbb_core/provider/standard_models/central_bank_holdings.py index b84d1ecaf3a1..0545f30afc50 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/central_bank_holdings.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/central_bank_holdings.py @@ -5,14 +5,13 @@ ) from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class CentralBankHoldingsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/cik_map.py b/openbb_platform/core/openbb_core/provider/standard_models/cik_map.py index 354117aa9e5b..30d497db8ce2 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/cik_map.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/cik_map.py @@ -2,14 +2,13 @@ from typing import Optional, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class CikMapQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/commercial_paper.py b/openbb_platform/core/openbb_core/provider/standard_models/commercial_paper.py index 2f4fc5cdb5cf..7abfa490149b 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/commercial_paper.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/commercial_paper.py @@ -5,14 +5,13 @@ ) from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class CommercialPaperParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/commodity_spot_prices.py b/openbb_platform/core/openbb_core/provider/standard_models/commodity_spot_prices.py index 75839fb84034..431a910d7745 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/commodity_spot_prices.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/commodity_spot_prices.py @@ -5,14 +5,13 @@ ) from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class CommoditySpotPricesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/company_filings.py b/openbb_platform/core/openbb_core/provider/standard_models/company_filings.py index f24df3ca9c96..5b5e444e3488 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/company_filings.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/company_filings.py @@ -7,14 +7,13 @@ from typing import List, Optional, Set, Union from dateutil import parser -from pydantic import Field, NonNegativeInt, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, NonNegativeInt, field_validator class CompanyFilingsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/company_news.py b/openbb_platform/core/openbb_core/provider/standard_models/company_news.py index 80433ecb6e69..e36a0d206023 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/company_news.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/company_news.py @@ -7,14 +7,13 @@ from typing import Dict, List, Optional from dateutil.relativedelta import relativedelta -from pydantic import Field, NonNegativeInt, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, NonNegativeInt, field_validator class CompanyNewsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/company_overview.py b/openbb_platform/core/openbb_core/provider/standard_models/company_overview.py index a563b1e9ea68..2963e5a378c8 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/company_overview.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/company_overview.py @@ -3,14 +3,13 @@ from datetime import date from typing import List, Optional, Set, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data, ForceInt from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class CompanyOverviewQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/compare_company_facts.py b/openbb_platform/core/openbb_core/provider/standard_models/compare_company_facts.py index cb5e01c17e12..41e75d325ca5 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/compare_company_facts.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/compare_company_facts.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class CompareCompanyFactsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/compare_groups.py b/openbb_platform/core/openbb_core/provider/standard_models/compare_groups.py index f33442c18844..6a9a4da65bfa 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/compare_groups.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/compare_groups.py @@ -2,10 +2,9 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams +from pydantic import Field class CompareGroupsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/composite_leading_indicator.py b/openbb_platform/core/openbb_core/provider/standard_models/composite_leading_indicator.py index 7a57771abac9..3a15b7300800 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/composite_leading_indicator.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/composite_leading_indicator.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class CompositeLeadingIndicatorQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/consumer_price_index.py b/openbb_platform/core/openbb_core/provider/standard_models/consumer_price_index.py index 0983d13d9d74..4d602c2e7104 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/consumer_price_index.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/consumer_price_index.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Literal, Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class ConsumerPriceIndexQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/cot.py b/openbb_platform/core/openbb_core/provider/standard_models/cot.py index 46bae53caf53..459ab0166d88 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/cot.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/cot.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class COTQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/cot_search.py b/openbb_platform/core/openbb_core/provider/standard_models/cot_search.py index e904ed2a0271..1942b99d6a64 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/cot_search.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/cot_search.py @@ -2,11 +2,10 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class CotSearchQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/country_interest_rates.py b/openbb_platform/core/openbb_core/provider/standard_models/country_interest_rates.py index bea3d0b361f7..4f4c5124c2c4 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/country_interest_rates.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/country_interest_rates.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class CountryInterestRatesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/country_profile.py b/openbb_platform/core/openbb_core/provider/standard_models/country_profile.py index 1dccae669c75..53ff1d2292f2 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/country_profile.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/country_profile.py @@ -2,14 +2,13 @@ from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class CountryProfileQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/crypto_historical.py b/openbb_platform/core/openbb_core/provider/standard_models/crypto_historical.py index 542536ffd9a2..0df4ea0f91cf 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/crypto_historical.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/crypto_historical.py @@ -7,14 +7,13 @@ from typing import List, Optional, Set, Union from dateutil import parser -from pydantic import Field, PositiveFloat, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, PositiveFloat, field_validator class CryptoHistoricalQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/crypto_search.py b/openbb_platform/core/openbb_core/provider/standard_models/crypto_search.py index b1334471d8b8..a82a4299fde9 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/crypto_search.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/crypto_search.py @@ -2,11 +2,10 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class CryptoSearchQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/currency_historical.py b/openbb_platform/core/openbb_core/provider/standard_models/currency_historical.py index ec98c4382e81..7df26fce6a9c 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/currency_historical.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/currency_historical.py @@ -6,14 +6,13 @@ ) from typing import List, Optional, Set, Union -from pydantic import Field, PositiveFloat, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, PositiveFloat, field_validator class CurrencyHistoricalQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/currency_pairs.py b/openbb_platform/core/openbb_core/provider/standard_models/currency_pairs.py index c910236c0d6f..669e87020aec 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/currency_pairs.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/currency_pairs.py @@ -2,11 +2,10 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class CurrencyPairsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/currency_reference_rates.py b/openbb_platform/core/openbb_core/provider/standard_models/currency_reference_rates.py index a0f3b9d23daf..db7438b4fe51 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/currency_reference_rates.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/currency_reference_rates.py @@ -5,11 +5,10 @@ ) from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class CurrencyReferenceRatesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/currency_snapshots.py b/openbb_platform/core/openbb_core/provider/standard_models/currency_snapshots.py index e0201ad6bbd2..1447e85b9d73 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/currency_snapshots.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/currency_snapshots.py @@ -2,11 +2,10 @@ from typing import List, Literal, Optional, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field, field_validator class CurrencySnapshotsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/direction_of_trade.py b/openbb_platform/core/openbb_core/provider/standard_models/direction_of_trade.py index 0360f155dc25..ca0c3680bcbd 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/direction_of_trade.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/direction_of_trade.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Literal, Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class DirectionOfTradeQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/discovery_filings.py b/openbb_platform/core/openbb_core/provider/standard_models/discovery_filings.py index 31effe386f18..f640a97ead78 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/discovery_filings.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/discovery_filings.py @@ -6,14 +6,13 @@ ) from typing import Optional -from pydantic import Field, NonNegativeInt - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, NonNegativeInt class DiscoveryFilingsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/dwpcr_rates.py b/openbb_platform/core/openbb_core/provider/standard_models/dwpcr_rates.py index 7ddb0f2e03e3..5141a412f5d8 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/dwpcr_rates.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/dwpcr_rates.py @@ -5,14 +5,13 @@ ) from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class DiscountWindowPrimaryCreditRateParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/earnings_call_transcript.py b/openbb_platform/core/openbb_core/provider/standard_models/earnings_call_transcript.py index d1dae96a0344..c947800d04c3 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/earnings_call_transcript.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/earnings_call_transcript.py @@ -3,14 +3,13 @@ from datetime import datetime from typing import List, Set, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class EarningsCallTranscriptQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/ecb_interest_rates.py b/openbb_platform/core/openbb_core/provider/standard_models/ecb_interest_rates.py index 13128cc12787..ce8f55a73233 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/ecb_interest_rates.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/ecb_interest_rates.py @@ -5,14 +5,13 @@ ) from typing import Literal, Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class EuropeanCentralBankInterestRatesParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/economic_calendar.py b/openbb_platform/core/openbb_core/provider/standard_models/economic_calendar.py index 67a268ce2b2f..4665c4e43516 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/economic_calendar.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/economic_calendar.py @@ -6,14 +6,13 @@ ) from typing import Optional, Union -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class EconomicCalendarQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/economic_indicators.py b/openbb_platform/core/openbb_core/provider/standard_models/economic_indicators.py index a20fe2690eb8..78c6f96357b5 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/economic_indicators.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/economic_indicators.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional, Union -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class EconomicIndicatorsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/equity_ftd.py b/openbb_platform/core/openbb_core/provider/standard_models/equity_ftd.py index 7ca5ad112122..427ed402a0eb 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/equity_ftd.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/equity_ftd.py @@ -6,14 +6,13 @@ ) from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class EquityFtdQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/equity_historical.py b/openbb_platform/core/openbb_core/provider/standard_models/equity_historical.py index 74fb8c175c5f..ab3f230319f8 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/equity_historical.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/equity_historical.py @@ -6,14 +6,13 @@ ) from typing import Optional, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class EquityHistoricalQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/equity_info.py b/openbb_platform/core/openbb_core/provider/standard_models/equity_info.py index 2a0fd383df94..274d62401ada 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/equity_info.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/equity_info.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class EquityInfoQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/equity_nbbo.py b/openbb_platform/core/openbb_core/provider/standard_models/equity_nbbo.py index baabe024e3f5..806221b45fdb 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/equity_nbbo.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/equity_nbbo.py @@ -1,10 +1,9 @@ """Equity NBBO Standard Model.""" -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field, field_validator class EquityNBBOQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/equity_ownership.py b/openbb_platform/core/openbb_core/provider/standard_models/equity_ownership.py index 48d47783c42a..d40c9102fd1d 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/equity_ownership.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/equity_ownership.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class EquityOwnershipQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/equity_peers.py b/openbb_platform/core/openbb_core/provider/standard_models/equity_peers.py index f8eae46248e6..5fb520752195 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/equity_peers.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/equity_peers.py @@ -2,11 +2,10 @@ from typing import List -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field, field_validator class EquityPeersQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/equity_performance.py b/openbb_platform/core/openbb_core/provider/standard_models/equity_performance.py index 8368962edf54..89711a1d9444 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/equity_performance.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/equity_performance.py @@ -2,11 +2,10 @@ from typing import Literal, Optional, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field, field_validator class EquityPerformanceQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/equity_quote.py b/openbb_platform/core/openbb_core/provider/standard_models/equity_quote.py index c98c7cfdfad8..21c35e0ed16e 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/equity_quote.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/equity_quote.py @@ -3,14 +3,13 @@ from datetime import datetime from typing import List, Optional, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class EquityQuoteQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/equity_screener.py b/openbb_platform/core/openbb_core/provider/standard_models/equity_screener.py index 486eaa004208..dde3e8f11bc3 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/equity_screener.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/equity_screener.py @@ -2,11 +2,10 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class EquityScreenerQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/equity_search.py b/openbb_platform/core/openbb_core/provider/standard_models/equity_search.py index 03ad1ec32584..43cac51869e9 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/equity_search.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/equity_search.py @@ -2,11 +2,10 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class EquitySearchQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/equity_short_interest.py b/openbb_platform/core/openbb_core/provider/standard_models/equity_short_interest.py index 8d1ef4b34a2c..0f1679ad1e8c 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/equity_short_interest.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/equity_short_interest.py @@ -2,14 +2,13 @@ from datetime import date as dateType -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class ShortInterestQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/equity_valuation_multiples.py b/openbb_platform/core/openbb_core/provider/standard_models/equity_valuation_multiples.py index c3581829611e..5f9d364accf0 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/equity_valuation_multiples.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/equity_valuation_multiples.py @@ -2,14 +2,13 @@ from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class EquityValuationMultiplesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/esg_risk_rating.py b/openbb_platform/core/openbb_core/provider/standard_models/esg_risk_rating.py index 6f7bb57d1df5..57c869e4c578 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/esg_risk_rating.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/esg_risk_rating.py @@ -2,14 +2,13 @@ from typing import List, Literal, Set, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class ESGRiskRatingQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/esg_score.py b/openbb_platform/core/openbb_core/provider/standard_models/esg_score.py index 073d1ab8e1a3..680f2a7a04df 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/esg_score.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/esg_score.py @@ -6,14 +6,13 @@ ) from typing import List, Set, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class ESGScoreQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/etf_countries.py b/openbb_platform/core/openbb_core/provider/standard_models/etf_countries.py index 290e04400d7c..e6af032eb9d0 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/etf_countries.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/etf_countries.py @@ -1,10 +1,9 @@ """ETF Countries Standard Model.""" -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field, field_validator class EtfCountriesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/etf_equity_exposure.py b/openbb_platform/core/openbb_core/provider/standard_models/etf_equity_exposure.py index b2ceb5f02ea9..36ae009c2463 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/etf_equity_exposure.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/etf_equity_exposure.py @@ -2,11 +2,10 @@ from typing import Optional, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field, field_validator class EtfEquityExposureQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/etf_historical.py b/openbb_platform/core/openbb_core/provider/standard_models/etf_historical.py index c3de3d54a7a3..5c5300e0bd5c 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/etf_historical.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/etf_historical.py @@ -7,14 +7,13 @@ from typing import Optional, Union from dateutil import parser -from pydantic import Field, NonNegativeInt, PositiveFloat, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, NonNegativeInt, PositiveFloat, field_validator class EtfHistoricalQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/etf_historical_nav.py b/openbb_platform/core/openbb_core/provider/standard_models/etf_historical_nav.py index 09c8574c5792..ae2425cd560f 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/etf_historical_nav.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/etf_historical_nav.py @@ -2,14 +2,13 @@ from datetime import date as dateType -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class EtfHistoricalNavQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/etf_holdings.py b/openbb_platform/core/openbb_core/provider/standard_models/etf_holdings.py index 0ad30366cd96..b591f769273e 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/etf_holdings.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/etf_holdings.py @@ -2,14 +2,13 @@ from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class EtfHoldingsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/etf_holdings_date.py b/openbb_platform/core/openbb_core/provider/standard_models/etf_holdings_date.py index 3a50102fbf70..f85786332319 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/etf_holdings_date.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/etf_holdings_date.py @@ -2,14 +2,13 @@ from datetime import date as dateType -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class EtfHoldingsDateQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/etf_info.py b/openbb_platform/core/openbb_core/provider/standard_models/etf_info.py index 20591c4be04f..ccc149c1919f 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/etf_info.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/etf_info.py @@ -2,14 +2,13 @@ from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class EtfInfoQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/etf_performance.py b/openbb_platform/core/openbb_core/provider/standard_models/etf_performance.py index 06eeb6c257b7..ad048377582d 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/etf_performance.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/etf_performance.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Literal, Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class ETFPerformanceQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/etf_search.py b/openbb_platform/core/openbb_core/provider/standard_models/etf_search.py index 12ea9ff83f5e..e0c217f4c171 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/etf_search.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/etf_search.py @@ -2,11 +2,10 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class EtfSearchQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/etf_sectors.py b/openbb_platform/core/openbb_core/provider/standard_models/etf_sectors.py index 8b353eedd22a..ef11759e3d8a 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/etf_sectors.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/etf_sectors.py @@ -2,11 +2,10 @@ from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field, field_validator class EtfSectorsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/eu_yield_curve.py b/openbb_platform/core/openbb_core/provider/standard_models/eu_yield_curve.py index eaf9efd68779..6e8012adf527 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/eu_yield_curve.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/eu_yield_curve.py @@ -3,11 +3,10 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field class EUYieldCurveQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/euro_short_term_rate.py b/openbb_platform/core/openbb_core/provider/standard_models/euro_short_term_rate.py index 9927f51dea03..d028f289fcdd 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/euro_short_term_rate.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/euro_short_term_rate.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class EuroShortTermRateQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/executive_compensation.py b/openbb_platform/core/openbb_core/provider/standard_models/executive_compensation.py index e2dea12ed254..9e871bdf14f0 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/executive_compensation.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/executive_compensation.py @@ -2,14 +2,13 @@ from typing import Optional -from pydantic import Field, NonNegativeFloat, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, NonNegativeFloat, field_validator class ExecutiveCompensationQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/export_destinations.py b/openbb_platform/core/openbb_core/provider/standard_models/export_destinations.py index 57fb4f1a93ea..7fa1da1390d9 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/export_destinations.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/export_destinations.py @@ -2,11 +2,10 @@ from typing import Union -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field class ExportDestinationsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/fed_projections.py b/openbb_platform/core/openbb_core/provider/standard_models/fed_projections.py index 48aefb384ce7..b87c9e726327 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/fed_projections.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/fed_projections.py @@ -3,11 +3,10 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class PROJECTIONQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/federal_funds_rate.py b/openbb_platform/core/openbb_core/provider/standard_models/federal_funds_rate.py index 960f9fe624ba..06e04df80330 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/federal_funds_rate.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/federal_funds_rate.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class FederalFundsRateQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/ffrmc.py b/openbb_platform/core/openbb_core/provider/standard_models/ffrmc.py index 8a8bba6d880d..203d34a7f45a 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/ffrmc.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/ffrmc.py @@ -5,14 +5,13 @@ ) from typing import Literal, Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class SelectedTreasuryConstantMaturityQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/financial_attributes.py b/openbb_platform/core/openbb_core/provider/standard_models/financial_attributes.py index af442f30d232..067a682b6bd9 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/financial_attributes.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/financial_attributes.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Literal, Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class FinancialAttributesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/financial_ratios.py b/openbb_platform/core/openbb_core/provider/standard_models/financial_ratios.py index 8d3fc02ede8e..fc19cb9efe44 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/financial_ratios.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/financial_ratios.py @@ -2,14 +2,13 @@ from typing import Optional -from pydantic import Field, NonNegativeInt, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, NonNegativeInt, field_validator class FinancialRatiosQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/forward_ebitda_estimates.py b/openbb_platform/core/openbb_core/provider/standard_models/forward_ebitda_estimates.py index 1fb19e8468b4..478b39e32fc8 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/forward_ebitda_estimates.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/forward_ebitda_estimates.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data, ForceInt from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class ForwardEbitdaEstimatesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/forward_eps_estimates.py b/openbb_platform/core/openbb_core/provider/standard_models/forward_eps_estimates.py index e0f95d9c8a1f..3988f267513f 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/forward_eps_estimates.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/forward_eps_estimates.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class ForwardEpsEstimatesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/forward_pe_estimates.py b/openbb_platform/core/openbb_core/provider/standard_models/forward_pe_estimates.py index 8888ce2ce2b6..c1baf6d67730 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/forward_pe_estimates.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/forward_pe_estimates.py @@ -2,14 +2,13 @@ from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class ForwardPeEstimatesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/forward_sales_estimates.py b/openbb_platform/core/openbb_core/provider/standard_models/forward_sales_estimates.py index 8d3e1217d586..14a01db21aa7 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/forward_sales_estimates.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/forward_sales_estimates.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data, ForceInt from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class ForwardSalesEstimatesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/fred_release_table.py b/openbb_platform/core/openbb_core/provider/standard_models/fred_release_table.py index 76f11202d41f..e7c0f2b7203f 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/fred_release_table.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/fred_release_table.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class ReleaseTableQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/fred_search.py b/openbb_platform/core/openbb_core/provider/standard_models/fred_search.py index d36217afc2a2..be64922b7c8e 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/fred_search.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/fred_search.py @@ -6,10 +6,9 @@ ) from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams +from pydantic import Field class SearchQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/fred_series.py b/openbb_platform/core/openbb_core/provider/standard_models/fred_series.py index e0e42b994953..a0c11843b54c 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/fred_series.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/fred_series.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class SeriesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/futures_curve.py b/openbb_platform/core/openbb_core/provider/standard_models/futures_curve.py index 3117a2bfa961..ece5d6d80f08 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/futures_curve.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/futures_curve.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class FuturesCurveQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/futures_historical.py b/openbb_platform/core/openbb_core/provider/standard_models/futures_historical.py index 4a4a3db07aee..95277188011f 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/futures_historical.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/futures_historical.py @@ -4,14 +4,13 @@ from typing import Optional from dateutil import parser -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class FuturesHistoricalQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/gdp_forecast.py b/openbb_platform/core/openbb_core/provider/standard_models/gdp_forecast.py index 5be679439de9..6f3adc58fd0b 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/gdp_forecast.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/gdp_forecast.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional, Union -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class GdpForecastQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/gdp_nominal.py b/openbb_platform/core/openbb_core/provider/standard_models/gdp_nominal.py index 078f25159ebb..e416767f8052 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/gdp_nominal.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/gdp_nominal.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional, Union -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class GdpNominalQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/gdp_real.py b/openbb_platform/core/openbb_core/provider/standard_models/gdp_real.py index 03cdc043a129..642d5cf39a26 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/gdp_real.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/gdp_real.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional, Union -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class GdpRealQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/high_quality_market.py b/openbb_platform/core/openbb_core/provider/standard_models/high_quality_market.py index 2152b00b4df3..5c63f7efcde5 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/high_quality_market.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/high_quality_market.py @@ -5,14 +5,13 @@ ) from typing import Optional, Union -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class HighQualityMarketCorporateBondQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/historical_attributes.py b/openbb_platform/core/openbb_core/provider/standard_models/historical_attributes.py index 39c3e58b44c1..51235dde3771 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/historical_attributes.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/historical_attributes.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import List, Literal, Optional, Set, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class HistoricalAttributesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/historical_dividends.py b/openbb_platform/core/openbb_core/provider/standard_models/historical_dividends.py index 5fb2c052839f..78068dd3ed82 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/historical_dividends.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/historical_dividends.py @@ -3,13 +3,12 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class HistoricalDividendsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/historical_employees.py b/openbb_platform/core/openbb_core/provider/standard_models/historical_employees.py index 6b958fe78067..19011fddfb4a 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/historical_employees.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/historical_employees.py @@ -3,14 +3,13 @@ from datetime import date, datetime from typing import List, Set, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class HistoricalEmployeesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/historical_eps.py b/openbb_platform/core/openbb_core/provider/standard_models/historical_eps.py index 025564be2bc8..141de6edc269 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/historical_eps.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/historical_eps.py @@ -4,14 +4,13 @@ from typing import Optional from dateutil import parser -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class HistoricalEpsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/historical_market_cap.py b/openbb_platform/core/openbb_core/provider/standard_models/historical_market_cap.py index ee722a0c8d72..149efd287ec6 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/historical_market_cap.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/historical_market_cap.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class HistoricalMarketCapQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/historical_splits.py b/openbb_platform/core/openbb_core/provider/standard_models/historical_splits.py index d088c65a1eeb..0342f485ab38 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/historical_splits.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/historical_splits.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class HistoricalSplitsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/house_price_index.py b/openbb_platform/core/openbb_core/provider/standard_models/house_price_index.py index 7e92b210b805..aa85600d6c43 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/house_price_index.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/house_price_index.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Literal, Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class HousePriceIndexQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/ice_bofa.py b/openbb_platform/core/openbb_core/provider/standard_models/ice_bofa.py index 97c93fde7cd6..725e6dff84ff 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/ice_bofa.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/ice_bofa.py @@ -5,14 +5,13 @@ ) from typing import Literal, Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class ICEBofAQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/immediate_interest_rate.py b/openbb_platform/core/openbb_core/provider/standard_models/immediate_interest_rate.py index 2143fc519bc1..90678728d410 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/immediate_interest_rate.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/immediate_interest_rate.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class ImmediateInterestRateQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/income_statement.py b/openbb_platform/core/openbb_core/provider/standard_models/income_statement.py index 23b8709af632..de752603942b 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/income_statement.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/income_statement.py @@ -3,13 +3,12 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, NonNegativeInt, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( QUERY_DESCRIPTIONS, ) +from pydantic import Field, NonNegativeInt, field_validator class IncomeStatementQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/income_statement_growth.py b/openbb_platform/core/openbb_core/provider/standard_models/income_statement_growth.py index 028783890f7e..5c9b15900540 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/income_statement_growth.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/income_statement_growth.py @@ -3,11 +3,10 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field, field_validator class IncomeStatementGrowthQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/index_historical.py b/openbb_platform/core/openbb_core/provider/standard_models/index_historical.py index 90f942fcf516..cacb738fd647 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/index_historical.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/index_historical.py @@ -7,14 +7,13 @@ from typing import Optional, Union from dateutil import parser -from pydantic import Field, StrictFloat, field_validator - from openbb_core.provider.abstract.data import Data, ForceInt from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, StrictFloat, field_validator class IndexHistoricalQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/index_info.py b/openbb_platform/core/openbb_core/provider/standard_models/index_info.py index 07dd1e3c79e2..07c734668c5c 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/index_info.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/index_info.py @@ -2,14 +2,13 @@ from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class IndexInfoQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/index_search.py b/openbb_platform/core/openbb_core/provider/standard_models/index_search.py index 7e63aefdff02..c60b98fcf41b 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/index_search.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/index_search.py @@ -1,10 +1,9 @@ """Index Search Standard Model.""" -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class IndexSearchQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/index_sectors.py b/openbb_platform/core/openbb_core/provider/standard_models/index_sectors.py index 0c870ff96f6a..43c2578d0421 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/index_sectors.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/index_sectors.py @@ -1,10 +1,9 @@ """Index Sectors Standard Model.""" -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field, field_validator class IndexSectorsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/index_snapshots.py b/openbb_platform/core/openbb_core/provider/standard_models/index_snapshots.py index 2a79932bf242..9844ad7f1e1b 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/index_snapshots.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/index_snapshots.py @@ -2,11 +2,10 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class IndexSnapshotsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/industry_pe.py b/openbb_platform/core/openbb_core/provider/standard_models/industry_pe.py index c019d49c6e26..4a9957465095 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/industry_pe.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/industry_pe.py @@ -3,11 +3,10 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class IndustryPEQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/insider_trading.py b/openbb_platform/core/openbb_core/provider/standard_models/insider_trading.py index 42da9e230000..b391a51bda85 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/insider_trading.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/insider_trading.py @@ -8,14 +8,13 @@ from typing import Optional, Union from dateutil import parser -from pydantic import Field, StrictInt, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, StrictInt, field_validator class InsiderTradingQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/institutional_ownership.py b/openbb_platform/core/openbb_core/provider/standard_models/institutional_ownership.py index be56f8c31fe1..66133c189395 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/institutional_ownership.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/institutional_ownership.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import List, Optional, Set, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class InstitutionalOwnershipQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/iorb_rates.py b/openbb_platform/core/openbb_core/provider/standard_models/iorb_rates.py index 3004152c12ad..8815fb0b6321 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/iorb_rates.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/iorb_rates.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class IORBQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/key_executives.py b/openbb_platform/core/openbb_core/provider/standard_models/key_executives.py index a3c4c2ef6cd7..9d875b4082e4 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/key_executives.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/key_executives.py @@ -2,11 +2,10 @@ from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data, ForceInt from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field, field_validator class KeyExecutivesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/key_metrics.py b/openbb_platform/core/openbb_core/provider/standard_models/key_metrics.py index 6eceb2ab02fa..475bc3d04685 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/key_metrics.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/key_metrics.py @@ -2,14 +2,13 @@ from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class KeyMetricsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/latest_attributes.py b/openbb_platform/core/openbb_core/provider/standard_models/latest_attributes.py index 2990365481da..562d02e908c9 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/latest_attributes.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/latest_attributes.py @@ -2,14 +2,13 @@ from typing import List, Optional, Set, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class LatestAttributesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/lbma_fixing.py b/openbb_platform/core/openbb_core/provider/standard_models/lbma_fixing.py index 3d99aacdbdcc..83139212ec9b 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/lbma_fixing.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/lbma_fixing.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Literal, Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class LbmaFixingQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/long_term_interest_rate.py b/openbb_platform/core/openbb_core/provider/standard_models/long_term_interest_rate.py index 713991e64e39..494c41466e2e 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/long_term_interest_rate.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/long_term_interest_rate.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class LTIRQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/manufacturing_outlook_texas.py b/openbb_platform/core/openbb_core/provider/standard_models/manufacturing_outlook_texas.py index 446340dd965f..5be3083e961b 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/manufacturing_outlook_texas.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/manufacturing_outlook_texas.py @@ -5,14 +5,13 @@ ) from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class ManufacturingOutlookTexasQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/market_movers.py b/openbb_platform/core/openbb_core/provider/standard_models/market_movers.py index 6055332615dc..c230e21b954d 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/market_movers.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/market_movers.py @@ -2,11 +2,10 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class MarketMoversQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/market_snapshots.py b/openbb_platform/core/openbb_core/provider/standard_models/market_snapshots.py index 887ab74b0cf0..0c38ca938b7e 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/market_snapshots.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/market_snapshots.py @@ -2,11 +2,10 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data, ForceInt from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class MarketSnapshotsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/money_measures.py b/openbb_platform/core/openbb_core/provider/standard_models/money_measures.py index b3ed3e557638..aa6c7c89b927 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/money_measures.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/money_measures.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class MoneyMeasuresQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/moody.py b/openbb_platform/core/openbb_core/provider/standard_models/moody.py index 0eddca2096f6..6c85e2ba72ff 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/moody.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/moody.py @@ -5,14 +5,13 @@ ) from typing import Literal, Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class MoodyCorporateBondIndexQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/mortgage_indices.py b/openbb_platform/core/openbb_core/provider/standard_models/mortgage_indices.py index bfba892bb2dd..8772ef794402 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/mortgage_indices.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/mortgage_indices.py @@ -5,14 +5,13 @@ ) from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class MortgageIndicesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/non_farm_payrolls.py b/openbb_platform/core/openbb_core/provider/standard_models/non_farm_payrolls.py index 912c777b157b..582e3fd749cf 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/non_farm_payrolls.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/non_farm_payrolls.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional, Union -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class NonFarmPayrollsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/options_chains.py b/openbb_platform/core/openbb_core/provider/standard_models/options_chains.py index bc0c4fa68164..a6909c96fe12 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/options_chains.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/options_chains.py @@ -6,14 +6,13 @@ ) from typing import List, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) from openbb_core.provider.utils.options_chains_properties import OptionsChainsProperties +from pydantic import Field, field_validator class OptionsChainsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/options_snapshots.py b/openbb_platform/core/openbb_core/provider/standard_models/options_snapshots.py index 5a3396f56bc3..4d01da1a9a50 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/options_snapshots.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/options_snapshots.py @@ -6,11 +6,10 @@ ) from typing import List, Union -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class OptionsSnapshotsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/options_unusual.py b/openbb_platform/core/openbb_core/provider/standard_models/options_unusual.py index 647e702925d7..dcbdd7f7c56a 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/options_unusual.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/options_unusual.py @@ -2,14 +2,13 @@ from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class OptionsUnusualQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/otc_aggregate.py b/openbb_platform/core/openbb_core/provider/standard_models/otc_aggregate.py index 63178d8e9c11..0085c8b7a40f 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/otc_aggregate.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/otc_aggregate.py @@ -3,11 +3,10 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field class OTCAggregateQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/overnight_bank_funding_rate.py b/openbb_platform/core/openbb_core/provider/standard_models/overnight_bank_funding_rate.py index 51afa516840c..20cd2c551d69 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/overnight_bank_funding_rate.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/overnight_bank_funding_rate.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class OvernightBankFundingRateQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/personal_consumption_expenditures.py b/openbb_platform/core/openbb_core/provider/standard_models/personal_consumption_expenditures.py index 1c621951c714..375690970044 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/personal_consumption_expenditures.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/personal_consumption_expenditures.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional, Union -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class PersonalConsumptionExpendituresQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/petroleum_status_report.py b/openbb_platform/core/openbb_core/provider/standard_models/petroleum_status_report.py index 607dab44d144..6d7b30c78a9a 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/petroleum_status_report.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/petroleum_status_report.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional, Union -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class PetroleumStatusReportQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/port_volume.py b/openbb_platform/core/openbb_core/provider/standard_models/port_volume.py index deb0c7b4c383..478aa6e0d291 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/port_volume.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/port_volume.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class PortVolumeQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/price_target.py b/openbb_platform/core/openbb_core/provider/standard_models/price_target.py index c8706a1d343a..9cdd9e0f875b 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/price_target.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/price_target.py @@ -7,14 +7,13 @@ ) from typing import Optional, Union -from pydantic import Field, NonNegativeInt, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, NonNegativeInt, field_validator class PriceTargetQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/price_target_consensus.py b/openbb_platform/core/openbb_core/provider/standard_models/price_target_consensus.py index 106879a884f7..9dd4ef8bc9ce 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/price_target_consensus.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/price_target_consensus.py @@ -2,14 +2,13 @@ from typing import List, Optional, Set, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class PriceTargetConsensusQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/primary_dealer_fails.py b/openbb_platform/core/openbb_core/provider/standard_models/primary_dealer_fails.py index a5f91f1f5757..f74105425e9d 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/primary_dealer_fails.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/primary_dealer_fails.py @@ -5,14 +5,13 @@ ) from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class PrimaryDealerFailsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/primary_dealer_positioning.py b/openbb_platform/core/openbb_core/provider/standard_models/primary_dealer_positioning.py index ff43b34100a2..8dd3b7940e1a 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/primary_dealer_positioning.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/primary_dealer_positioning.py @@ -5,14 +5,13 @@ ) from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class PrimaryDealerPositioningQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/recent_performance.py b/openbb_platform/core/openbb_core/provider/standard_models/recent_performance.py index 3955e4eacd74..ae4147554449 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/recent_performance.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/recent_performance.py @@ -2,14 +2,13 @@ from typing import Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class RecentPerformanceQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/reported_financials.py b/openbb_platform/core/openbb_core/provider/standard_models/reported_financials.py index d8187d576c52..287d7562b414 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/reported_financials.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/reported_financials.py @@ -3,13 +3,12 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field, field_validator, model_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator, model_validator class ReportedFinancialsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/retail_prices.py b/openbb_platform/core/openbb_core/provider/standard_models/retail_prices.py index 3f0996e411da..0f042489399f 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/retail_prices.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/retail_prices.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class RetailPricesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/revenue_business_line.py b/openbb_platform/core/openbb_core/provider/standard_models/revenue_business_line.py index 20d62be8b84b..57a2c9c3f272 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/revenue_business_line.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/revenue_business_line.py @@ -3,11 +3,10 @@ from datetime import date as dateType from typing import Optional, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field, field_validator class RevenueBusinessLineQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/revenue_geographic.py b/openbb_platform/core/openbb_core/provider/standard_models/revenue_geographic.py index 507da189f824..1684bbc506fc 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/revenue_geographic.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/revenue_geographic.py @@ -3,11 +3,10 @@ from datetime import date as dateType from typing import Optional, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field, field_validator class RevenueGeographicQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/risk_premium.py b/openbb_platform/core/openbb_core/provider/standard_models/risk_premium.py index 92e4fb852d08..4431d481279a 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/risk_premium.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/risk_premium.py @@ -2,10 +2,9 @@ from typing import Optional -from pydantic import Field, NonNegativeFloat, PositiveFloat - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams +from pydantic import Field, NonNegativeFloat, PositiveFloat class RiskPremiumQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/search_attributes.py b/openbb_platform/core/openbb_core/provider/standard_models/search_attributes.py index 74ee17babceb..dd2d8b14bc86 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/search_attributes.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/search_attributes.py @@ -2,11 +2,10 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field class SearchAttributesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/search_financial_attributes.py b/openbb_platform/core/openbb_core/provider/standard_models/search_financial_attributes.py index 9b3f96d2e3fb..62f6ffef63e3 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/search_financial_attributes.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/search_financial_attributes.py @@ -2,11 +2,10 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field class SearchFinancialAttributesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/sector_pe.py b/openbb_platform/core/openbb_core/provider/standard_models/sector_pe.py index 63d463525cbc..23fef084c7d4 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/sector_pe.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/sector_pe.py @@ -3,11 +3,10 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import DATA_DESCRIPTIONS +from pydantic import Field class SectorPEQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/sector_performance.py b/openbb_platform/core/openbb_core/provider/standard_models/sector_performance.py index 478f5baf509c..c8db32ba4450 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/sector_performance.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/sector_performance.py @@ -1,9 +1,8 @@ """Sector Performance Standard Model.""" -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams +from pydantic import Field class SectorPerformanceQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/senior_loan_officer_survey.py b/openbb_platform/core/openbb_core/provider/standard_models/senior_loan_officer_survey.py index bb224ef8c8fa..c3e5c4395c3d 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/senior_loan_officer_survey.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/senior_loan_officer_survey.py @@ -5,14 +5,13 @@ ) from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class SeniorLoanOfficerSurveyQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/share_price_index.py b/openbb_platform/core/openbb_core/provider/standard_models/share_price_index.py index ff2d06816754..cf3ddd6f919d 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/share_price_index.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/share_price_index.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Literal, Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class SharePriceIndexQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/share_statistics.py b/openbb_platform/core/openbb_core/provider/standard_models/share_statistics.py index f625094c9412..10eca8e12755 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/share_statistics.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/share_statistics.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import List, Optional, Set, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class ShareStatisticsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/short_term_energy_outlook.py b/openbb_platform/core/openbb_core/provider/standard_models/short_term_energy_outlook.py index 8bda72ccc239..06734a146d3a 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/short_term_energy_outlook.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/short_term_energy_outlook.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional, Union -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class ShortTermEnergyOutlookQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/short_term_interest_rate.py b/openbb_platform/core/openbb_core/provider/standard_models/short_term_interest_rate.py index 87bfd6c5b1e6..057584597f03 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/short_term_interest_rate.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/short_term_interest_rate.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class STIRQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/short_volume.py b/openbb_platform/core/openbb_core/provider/standard_models/short_volume.py index 020f819da157..809885214732 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/short_volume.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/short_volume.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class ShortVolumeQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/sofr.py b/openbb_platform/core/openbb_core/provider/standard_models/sofr.py index d15bee0aebe4..e8786e9e8418 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/sofr.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/sofr.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class SOFRQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/sonia_rates.py b/openbb_platform/core/openbb_core/provider/standard_models/sonia_rates.py index 771ec4d8d841..14fc2264079e 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/sonia_rates.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/sonia_rates.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class SONIAQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/sp500_multiples.py b/openbb_platform/core/openbb_core/provider/standard_models/sp500_multiples.py index b09a0d98b3e0..2fb390a8f5d8 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/sp500_multiples.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/sp500_multiples.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Literal, Optional, Union -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field SERIES_NAME = Literal[ "shiller_pe_month", diff --git a/openbb_platform/core/openbb_core/provider/standard_models/spot.py b/openbb_platform/core/openbb_core/provider/standard_models/spot.py index b635aa622356..4980c65e4261 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/spot.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/spot.py @@ -5,14 +5,13 @@ ) from typing import Optional, Union -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class SpotRateQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/survey_of_economic_conditions_chicago.py b/openbb_platform/core/openbb_core/provider/standard_models/survey_of_economic_conditions_chicago.py index c44b6a99468e..fa5dbec9a42c 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/survey_of_economic_conditions_chicago.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/survey_of_economic_conditions_chicago.py @@ -5,14 +5,13 @@ ) from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class SurveyOfEconomicConditionsChicagoQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/symbol_map.py b/openbb_platform/core/openbb_core/provider/standard_models/symbol_map.py index b47d43827672..fff5ecd6e54a 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/symbol_map.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/symbol_map.py @@ -2,9 +2,8 @@ from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.query_params import QueryParams +from pydantic import Field class SymbolMapQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/tbffr.py b/openbb_platform/core/openbb_core/provider/standard_models/tbffr.py index 33caa8df1c3c..0c72d3347f86 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/tbffr.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/tbffr.py @@ -5,14 +5,13 @@ ) from typing import Literal, Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class SelectedTreasuryBillQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/tips_yields.py b/openbb_platform/core/openbb_core/provider/standard_models/tips_yields.py index e51ae0a85de1..14db13dae7ea 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/tips_yields.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/tips_yields.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class TipsYieldsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/tmc.py b/openbb_platform/core/openbb_core/provider/standard_models/tmc.py index 7ccb66d8d032..b78b80e87d23 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/tmc.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/tmc.py @@ -5,14 +5,13 @@ ) from typing import Literal, Optional -from pydantic import Field, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, field_validator class TreasuryConstantMaturityQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/top_retail.py b/openbb_platform/core/openbb_core/provider/standard_models/top_retail.py index f571e262a20e..580ecf5d2773 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/top_retail.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/top_retail.py @@ -2,14 +2,13 @@ from datetime import date as DateType -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class TopRetailQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/trailing_dividend_yield.py b/openbb_platform/core/openbb_core/provider/standard_models/trailing_dividend_yield.py index b3aa8ebed660..bc23c63dfb79 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/trailing_dividend_yield.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/trailing_dividend_yield.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class TrailingDivYieldQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/treasury_auctions.py b/openbb_platform/core/openbb_core/provider/standard_models/treasury_auctions.py index 01d684c3a881..51cf15b51b61 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/treasury_auctions.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/treasury_auctions.py @@ -7,11 +7,10 @@ ) from typing import Literal, Optional -from pydantic import Field, model_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field, model_validator class USTreasuryAuctionsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/treasury_prices.py b/openbb_platform/core/openbb_core/provider/standard_models/treasury_prices.py index a91544836fd1..332ab155ea13 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/treasury_prices.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/treasury_prices.py @@ -3,11 +3,10 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field class TreasuryPricesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/treasury_rates.py b/openbb_platform/core/openbb_core/provider/standard_models/treasury_rates.py index 93149d1c3776..a29f81da063a 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/treasury_rates.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/treasury_rates.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class TreasuryRatesQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/unemployment.py b/openbb_platform/core/openbb_core/provider/standard_models/unemployment.py index 4380719fd77d..62d2766da208 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/unemployment.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/unemployment.py @@ -3,14 +3,13 @@ from datetime import date as dateType from typing import Literal, Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class UnemploymentQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/university_of_michigan.py b/openbb_platform/core/openbb_core/provider/standard_models/university_of_michigan.py index 140e698f7e9d..2327d5d52d03 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/university_of_michigan.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/university_of_michigan.py @@ -5,14 +5,13 @@ ) from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field class UofMichiganQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/us_yield_curve.py b/openbb_platform/core/openbb_core/provider/standard_models/us_yield_curve.py index 92c95baf2322..de7a87ffc333 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/us_yield_curve.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/us_yield_curve.py @@ -3,11 +3,10 @@ from datetime import date as dateType from typing import Optional -from pydantic import Field - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import QUERY_DESCRIPTIONS +from pydantic import Field class USYieldCurveQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/standard_models/world_news.py b/openbb_platform/core/openbb_core/provider/standard_models/world_news.py index 085cb82679ac..72bc3fe91df3 100644 --- a/openbb_platform/core/openbb_core/provider/standard_models/world_news.py +++ b/openbb_platform/core/openbb_core/provider/standard_models/world_news.py @@ -7,14 +7,13 @@ from typing import Dict, List, Optional from dateutil.relativedelta import relativedelta -from pydantic import Field, NonNegativeInt, field_validator - from openbb_core.provider.abstract.data import Data from openbb_core.provider.abstract.query_params import QueryParams from openbb_core.provider.utils.descriptions import ( DATA_DESCRIPTIONS, QUERY_DESCRIPTIONS, ) +from pydantic import Field, NonNegativeInt, field_validator class WorldNewsQueryParams(QueryParams): diff --git a/openbb_platform/core/openbb_core/provider/utils/helpers.py b/openbb_platform/core/openbb_core/provider/utils/helpers.py index d21aefd68a99..908dfe413d1b 100644 --- a/openbb_platform/core/openbb_core/provider/utils/helpers.py +++ b/openbb_platform/core/openbb_core/provider/utils/helpers.py @@ -19,14 +19,13 @@ ) from anyio.from_thread import start_blocking_portal -from typing_extensions import ParamSpec - from openbb_core.provider.abstract.data import Data from openbb_core.provider.utils.client import ( ClientResponse, ClientSession, get_user_agent, ) +from typing_extensions import ParamSpec if TYPE_CHECKING: from requests import Response # pylint: disable=import-outside-toplevel diff --git a/openbb_platform/core/tests/app/static/test_container.py b/openbb_platform/core/tests/app/static/test_container.py index a19b1331b096..2e128432b5db 100644 --- a/openbb_platform/core/tests/app/static/test_container.py +++ b/openbb_platform/core/tests/app/static/test_container.py @@ -89,7 +89,8 @@ def test_container__check_credentials(container): OpenBBError, escape( "Provider fallback failed." - "\n[Providers]\n * 'x' -> not installed, please install openbb-x\n * 'y' -> not installed, please install openbb-y\n * 'z' -> not installed, please install openbb-z" + "\n[Providers]\n * 'x' -> not installed, please install openbb-x\n * 'y' -> not installed," + " please install openbb-y\n * 'z' -> not installed, please install openbb-z" ), ), ], diff --git a/openbb_platform/core/tests/app/static/test_package_builder.py b/openbb_platform/core/tests/app/static/test_package_builder.py index fe738d69debb..469148a5dfce 100644 --- a/openbb_platform/core/tests/app/static/test_package_builder.py +++ b/openbb_platform/core/tests/app/static/test_package_builder.py @@ -130,7 +130,7 @@ class TestField: field = TestField() result = method_definition.get_type(field) - assert result == int + assert result is int def test_field_with_type_attribute_missing_type(method_definition): From d53dd0c0612a4d88646bab650e2ca755168bce70 Mon Sep 17 00:00:00 2001 From: Danglewood <85772166+deeleeramone@users.noreply.github.com> Date: Thu, 5 Dec 2024 23:13:12 -0800 Subject: [PATCH 2/5] rest of the repo --- cli/openbb_cli/controllers/utils.py | 2 +- cli/tests/test_controllers_utils.py | 2 +- .../derivatives/openbb_derivatives/derivatives_views.py | 2 +- .../technical/openbb_technical/technical_views.py | 2 +- .../obbject_extensions/charting/openbb_charting/charting.py | 2 +- .../charting/openbb_charting/core/openbb_figure.py | 6 +++--- openbb_platform/providers/imf/openbb_imf/__init__.py | 1 - .../providers/imf/openbb_imf/models/direction_of_trade.py | 1 - 8 files changed, 8 insertions(+), 10 deletions(-) diff --git a/cli/openbb_cli/controllers/utils.py b/cli/openbb_cli/controllers/utils.py index 46beed4b7953..0b05ad75a969 100644 --- a/cli/openbb_cli/controllers/utils.py +++ b/cli/openbb_cli/controllers/utils.py @@ -259,7 +259,7 @@ def parse_and_split_input(an_input: str, custom_filters: List) -> List[str]: commands = an_input.split("/") if "timezone" not in an_input else [an_input] for command_num, command in enumerate(commands): - if command == commands[command_num] == commands[-1] == "": + if command == command == commands[-1] == "": return list(filter(None, commands)) matching_placeholders = [tag for tag in placeholders if tag in command] if len(matching_placeholders) > 0: diff --git a/cli/tests/test_controllers_utils.py b/cli/tests/test_controllers_utils.py index f582c91f821e..e5a842170a64 100644 --- a/cli/tests/test_controllers_utils.py +++ b/cli/tests/test_controllers_utils.py @@ -102,7 +102,7 @@ def test_get_flair_and_username(mock_session): """Test getting the flair and username.""" result = get_flair_and_username() assert "testuser" in result - assert "rocket" in result # + assert "rocket" in result @pytest.mark.parametrize( diff --git a/openbb_platform/extensions/derivatives/openbb_derivatives/derivatives_views.py b/openbb_platform/extensions/derivatives/openbb_derivatives/derivatives_views.py index ed4409e29bbc..ce1b4b909847 100644 --- a/openbb_platform/extensions/derivatives/openbb_derivatives/derivatives_views.py +++ b/openbb_platform/extensions/derivatives/openbb_derivatives/derivatives_views.py @@ -76,7 +76,7 @@ def derivatives_futures_curve( # noqa: PLR0912 from openbb_core.provider.abstract.data import Data from pandas import DataFrame, to_datetime - data = kwargs.get("data", None) + data = kwargs.get("data") symbol = kwargs.get("standard_params", {}).get("symbol", "") df: DataFrame = DataFrame() if data: diff --git a/openbb_platform/extensions/technical/openbb_technical/technical_views.py b/openbb_platform/extensions/technical/openbb_technical/technical_views.py index 761ff78ba43c..c8473e928837 100644 --- a/openbb_platform/extensions/technical/openbb_technical/technical_views.py +++ b/openbb_platform/extensions/technical/openbb_technical/technical_views.py @@ -348,7 +348,7 @@ def technical_relative_rotation( ratios_df = basemodel_to_df(kwargs["obbject_item"].rs_ratios, index="date") # type: ignore momentum_df = basemodel_to_df(kwargs["obbject_item"].rs_momentum, index="date") # type: ignore benchmark_symbol = kwargs["obbject_item"].benchmark # type: ignore - study = kwargs.get("study", None) + study = kwargs.get("study") study = str(kwargs["obbject_item"].study) if study is None else str(study) show_tails = kwargs.get("show_tails") show_tails = True if show_tails is None else show_tails diff --git a/openbb_platform/obbject_extensions/charting/openbb_charting/charting.py b/openbb_platform/obbject_extensions/charting/openbb_charting/charting.py index 4f400ebd8c70..119a2b9337d3 100644 --- a/openbb_platform/obbject_extensions/charting/openbb_charting/charting.py +++ b/openbb_platform/obbject_extensions/charting/openbb_charting/charting.py @@ -425,7 +425,7 @@ def show(self, render: bool = True, **kwargs): self._obbject._route # pylint: disable=protected-access ) kwargs["obbject_item"] = self._obbject.results - kwargs["charting_settings"] = self._charting_settings # + kwargs["charting_settings"] = self._charting_settings kwargs["standard_params"] = ( self._obbject._standard_params # pylint: disable=protected-access ) diff --git a/openbb_platform/obbject_extensions/charting/openbb_charting/core/openbb_figure.py b/openbb_platform/obbject_extensions/charting/openbb_charting/core/openbb_figure.py index 9db03e0605e7..6b1b10b2cb1a 100644 --- a/openbb_platform/obbject_extensions/charting/openbb_charting/core/openbb_figure.py +++ b/openbb_platform/obbject_extensions/charting/openbb_charting/core/openbb_figure.py @@ -486,7 +486,7 @@ def set_title( if wrap: title = "
".join(textwrap.wrap(title, width=wrap_width)) - if kwargs.get("row", None) is not None and kwargs.get("col", None) is not None: + if kwargs.get("row") is not None and kwargs.get("col") is not None: self.add_annotation( text=title, xref="x domain", @@ -1392,11 +1392,11 @@ def to_table( header_values, cell_values = cls._tbl_values(data, print_index) - if (height := kwargs.get("height", None)) and height < len( + if (height := kwargs.get("height")) and height < len( data.index ) * 28 + 25: kwargs.pop("height") - if (width := kwargs.get("width", None)) and width < sum(columnwidth) * 8.7: + if (width := kwargs.get("width")) and width < sum(columnwidth) * 8.7: kwargs.pop("width") height = kwargs.pop("height", len(data.index) * 28 + 25) diff --git a/openbb_platform/providers/imf/openbb_imf/__init__.py b/openbb_platform/providers/imf/openbb_imf/__init__.py index ae48c2aadf0b..12fdc93e5ac5 100644 --- a/openbb_platform/providers/imf/openbb_imf/__init__.py +++ b/openbb_platform/providers/imf/openbb_imf/__init__.py @@ -1,7 +1,6 @@ """OpenBB IMF Provider Module.""" from openbb_core.provider.abstract.provider import Provider - from openbb_imf.models.available_indicators import ImfAvailableIndicatorsFetcher from openbb_imf.models.direction_of_trade import ImfDirectionOfTradeFetcher from openbb_imf.models.economic_indicators import ImfEconomicIndicatorsFetcher diff --git a/openbb_platform/providers/imf/openbb_imf/models/direction_of_trade.py b/openbb_platform/providers/imf/openbb_imf/models/direction_of_trade.py index df02d941e43f..3b6c2e1f2e13 100644 --- a/openbb_platform/providers/imf/openbb_imf/models/direction_of_trade.py +++ b/openbb_platform/providers/imf/openbb_imf/models/direction_of_trade.py @@ -12,7 +12,6 @@ DirectionOfTradeQueryParams, ) from openbb_core.provider.utils.errors import EmptyDataError - from openbb_imf.utils.dot_helpers import ( load_country_map, load_country_to_code_map, From 7f33301725a6b13f380bba2472f64736cf96c6f2 Mon Sep 17 00:00:00 2001 From: Danglewood <85772166+deeleeramone@users.noreply.github.com> Date: Thu, 5 Dec 2024 23:19:16 -0800 Subject: [PATCH 3/5] black --- openbb_platform/core/openbb_core/api/router/commands.py | 4 +--- .../charting/openbb_charting/core/openbb_figure.py | 4 +--- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/openbb_platform/core/openbb_core/api/router/commands.py b/openbb_platform/core/openbb_core/api/router/commands.py index dc029220a074..f5239199c5cf 100644 --- a/openbb_platform/core/openbb_core/api/router/commands.py +++ b/openbb_platform/core/openbb_core/api/router/commands.py @@ -203,9 +203,7 @@ async def wrapper(*args: Tuple[Any], **kwargs: Dict[str, Any]) -> OBBject: ) if defaults: - provider_choices = getattr( - kwargs.get("provider_choices"), "__dict__", {} - ) + provider_choices = getattr(kwargs.get("provider_choices"), "__dict__", {}) _provider = defaults.pop("provider", None) if ( diff --git a/openbb_platform/obbject_extensions/charting/openbb_charting/core/openbb_figure.py b/openbb_platform/obbject_extensions/charting/openbb_charting/core/openbb_figure.py index 6b1b10b2cb1a..aa73fea9118b 100644 --- a/openbb_platform/obbject_extensions/charting/openbb_charting/core/openbb_figure.py +++ b/openbb_platform/obbject_extensions/charting/openbb_charting/core/openbb_figure.py @@ -1392,9 +1392,7 @@ def to_table( header_values, cell_values = cls._tbl_values(data, print_index) - if (height := kwargs.get("height")) and height < len( - data.index - ) * 28 + 25: + if (height := kwargs.get("height")) and height < len(data.index) * 28 + 25: kwargs.pop("height") if (width := kwargs.get("width")) and width < sum(columnwidth) * 8.7: kwargs.pop("width") From 80f90ab2c179394c8063b7c5a894689c53bcffd4 Mon Sep 17 00:00:00 2001 From: Danglewood <85772166+deeleeramone@users.noreply.github.com> Date: Thu, 5 Dec 2024 23:28:57 -0800 Subject: [PATCH 4/5] type: ignore --- cli/openbb_cli/argparse_translator/obbject_registry.py | 4 ++-- .../core/openbb_core/app/static/package_builder.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cli/openbb_cli/argparse_translator/obbject_registry.py b/cli/openbb_cli/argparse_translator/obbject_registry.py index 2a802e94b9eb..b60815d9e403 100644 --- a/cli/openbb_cli/argparse_translator/obbject_registry.py +++ b/cli/openbb_cli/argparse_translator/obbject_registry.py @@ -93,9 +93,9 @@ def _handle_data_repr(obbject: OBBject) -> str: else "" ) if data_schema and "title" in data_schema: - data_repr = f"{data_schema['title']}" + data_repr = f"{data_schema['title']}" # type: ignore if data_schema and "description" in data_schema: - data_repr += f" - {data_schema['description'].split('.')[0]}" + data_repr += f" - {data_schema['description'].split('.')[0]}" # type: ignore return data_repr diff --git a/openbb_platform/core/openbb_core/app/static/package_builder.py b/openbb_platform/core/openbb_core/app/static/package_builder.py index 67892977bd18..2ab410f9131f 100644 --- a/openbb_platform/core/openbb_core/app/static/package_builder.py +++ b/openbb_platform/core/openbb_core/app/static/package_builder.py @@ -1095,7 +1095,7 @@ def get_param_info(parameter: Optional[Parameter]) -> Tuple[str, str]: ) metadata = getattr(annotation, "__metadata__", []) description = getattr(metadata[0], "description", "") if metadata else "" - return type_, description + return type_, description # type: ignore # Description summary if "description" in sections: From 24448a5ad35078bd4441a59f36383b7acafb8a67 Mon Sep 17 00:00:00 2001 From: Danglewood <85772166+deeleeramone@users.noreply.github.com> Date: Thu, 5 Dec 2024 23:56:12 -0800 Subject: [PATCH 5/5] more linting --- cli/openbb_cli/controllers/utils.py | 8 ++++---- openbb_platform/core/openbb_core/app/command_runner.py | 2 +- .../core/openbb_core/app/static/package_builder.py | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/cli/openbb_cli/controllers/utils.py b/cli/openbb_cli/controllers/utils.py index 0b05ad75a969..d21591197f58 100644 --- a/cli/openbb_cli/controllers/utils.py +++ b/cli/openbb_cli/controllers/utils.py @@ -259,7 +259,7 @@ def parse_and_split_input(an_input: str, custom_filters: List) -> List[str]: commands = an_input.split("/") if "timezone" not in an_input else [an_input] for command_num, command in enumerate(commands): - if command == command == commands[-1] == "": + if command == commands[-1] == "": return list(filter(None, commands)) matching_placeholders = [tag for tag in placeholders if tag in command] if len(matching_placeholders) > 0: @@ -300,7 +300,7 @@ def return_colored_value(value: str): return f"{value}" -# pylint: disable=too-many-arguments +# pylint: disable=too-many-arguments,too-many-positional-arguments def print_rich_table( # noqa: PLR0912 df: pd.DataFrame, show_index: bool = False, @@ -753,7 +753,7 @@ def ask_file_overwrite(file_path: Path) -> Tuple[bool, bool]: # This is a false positive on pylint and being tracked in pylint #3060 -# pylint: disable=abstract-class-instantiated +# pylint: disable=abstract-class-instantiated,too-many-positional-arguments def save_to_excel(df, saved_path, sheet_name, start_row=0, index=True, header=True): """Save a Pandas DataFrame to an Excel file. @@ -803,7 +803,7 @@ def save_to_excel(df, saved_path, sheet_name, start_row=0, index=True, header=Tr # This is a false positive on pylint and being tracked in pylint #3060 -# pylint: disable=abstract-class-instantiated +# pylint: disable=abstract-class-instantiated,too-many-positional-arguments def export_data( export_type: str, dir_path: str, diff --git a/openbb_platform/core/openbb_core/app/command_runner.py b/openbb_platform/core/openbb_core/app/command_runner.py index 9d83f9a2df03..c050c6ae3406 100644 --- a/openbb_platform/core/openbb_core/app/command_runner.py +++ b/openbb_platform/core/openbb_core/app/command_runner.py @@ -272,7 +272,7 @@ def _extract_params(cls, kwargs, key) -> Dict: # pylint: disable=R0913, R0914 @classmethod - async def _execute_func( + async def _execute_func( # pylint: disable=too-many-positional-arguments cls, route: str, args: Tuple[Any, ...], diff --git a/openbb_platform/core/openbb_core/app/static/package_builder.py b/openbb_platform/core/openbb_core/app/static/package_builder.py index 2ab410f9131f..9dee1cf57520 100644 --- a/openbb_platform/core/openbb_core/app/static/package_builder.py +++ b/openbb_platform/core/openbb_core/app/static/package_builder.py @@ -1045,7 +1045,7 @@ def build_examples( return "" @classmethod - def generate_model_docstring( + def generate_model_docstring( # pylint: disable=too-many-positional-arguments cls, model_name: str, summary: str, @@ -1150,7 +1150,7 @@ def get_param_info(parameter: Optional[Parameter]) -> Tuple[str, str]: return docstring @classmethod - def generate( + def generate( # pylint: disable=too-many-positional-arguments cls, path: str, func: Callable,