diff options
author | Henrique Joaquim <h.joaquim@campus.fct.unl.pt> | 2024-01-29 13:37:21 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-01-29 13:37:21 +0000 |
commit | 4163f477d4f455e2620a318f257965d4440ca426 (patch) | |
tree | 394290268b1c7a7740e580379d4b5c0a072440ca | |
parent | 2d7c5c68fe1f77b7cc3a509b48df07e562d43c8c (diff) |
format w new black (#6009)
* format w new black
* format w new black
* black again
* black the terminal
* ignoring unused arguments
---------
Co-authored-by: Pratyush Shukla <ps4534@nyu.edu>
5 files changed, 7 insertions, 4 deletions
diff --git a/openbb_platform/providers/cboe/openbb_cboe/models/index_historical.py b/openbb_platform/providers/cboe/openbb_cboe/models/index_historical.py index a45f44269d8..32015ce3d9c 100644 --- a/openbb_platform/providers/cboe/openbb_cboe/models/index_historical.py +++ b/openbb_platform/providers/cboe/openbb_cboe/models/index_historical.py @@ -101,6 +101,7 @@ class CboeIndexHistoricalFetcher( return CboeIndexHistoricalQueryParams(**transformed_params) + # pylint: disable=unused-argument @staticmethod async def aextract_data( query: CboeIndexHistoricalQueryParams, @@ -108,7 +109,6 @@ class CboeIndexHistoricalFetcher( **kwargs: Any, ) -> List[Dict]: """Return the raw data from the Cboe endpoint.""" - symbols = query.symbol.split(",") INDEXES = await get_index_directory(use_cache=query.use_cache) INDEXES = INDEXES.set_index("index_symbol") @@ -156,6 +156,7 @@ class CboeIndexHistoricalFetcher( return await amake_requests(urls, **kwargs) + # pylint: disable=unused-argument @staticmethod def transform_data( query: CboeIndexHistoricalQueryParams, data: List[Dict], **kwargs: Any diff --git a/openbb_platform/providers/fred/openbb_fred/models/dwpcr_rates.py b/openbb_platform/providers/fred/openbb_fred/models/dwpcr_rates.py index 24c63ff94a4..f78aed61f7f 100644 --- a/openbb_platform/providers/fred/openbb_fred/models/dwpcr_rates.py +++ b/openbb_platform/providers/fred/openbb_fred/models/dwpcr_rates.py @@ -78,9 +78,10 @@ class FREDDiscountWindowPrimaryCreditRateFetcher( return data + # pylint: disable=unused-argument @staticmethod def transform_data( query: FREDDiscountWindowPrimaryCreditRateParams, data: list, **kwargs: Any ) -> List[FREDDiscountWindowPrimaryCreditRateData]: - """Transform data""" + """Transform data.""" return [FREDDiscountWindowPrimaryCreditRateData.model_validate(d) for d in data] diff --git a/openbb_platform/providers/fred/openbb_fred/models/series.py b/openbb_platform/providers/fred/openbb_fred/models/series.py index e9f88e5b722..486d351ecc8 100644 --- a/openbb_platform/providers/fred/openbb_fred/models/series.py +++ b/openbb_platform/providers/fred/openbb_fred/models/series.py @@ -122,7 +122,6 @@ class FredSeriesFetcher( **kwargs: Any, ) -> Dict: """Extract data.""" - api_key = credentials.get("fred_api_key") if credentials else "" base_url = "https://api.stlouisfed.org/fred/series/observations" @@ -186,6 +185,7 @@ class FredSeriesFetcher( return data + # pylint: disable=unused-argument @staticmethod def transform_data( query: FredSeriesQueryParams, data: Dict, **kwargs: Any diff --git a/openbb_platform/providers/nasdaq/openbb_nasdaq/models/sp500_multiples.py b/openbb_platform/providers/nasdaq/openbb_nasdaq/models/sp500_multiples.py index 969359e7ad2..506f3ab10ea 100644 --- a/openbb_platform/providers/nasdaq/openbb_nasdaq/models/sp500_multiples.py +++ b/openbb_platform/providers/nasdaq/openbb_nasdaq/models/sp500_multiples.py @@ -38,6 +38,7 @@ class NasdaqSP500MultiplesFetcher( @staticmethod def transform_query(params: Dict[str, Any]) -> NasdaqSP500MultiplesQueryParams: + """Transform the query.""" return NasdaqSP500MultiplesQueryParams(**params) @staticmethod @@ -71,6 +72,7 @@ class NasdaqSP500MultiplesFetcher( return data.to_dict("records") + # pylint: disable=unused-argument @staticmethod def transform_data( query: NasdaqSP500MultiplesQueryParams, diff --git a/openbb_platform/providers/sec/openbb_sec/models/etf_holdings.py b/openbb_platform/providers/sec/openbb_sec/models/etf_holdings.py index e25853e296e..19a0c9d0627 100644 --- a/openbb_platform/providers/sec/openbb_sec/models/etf_holdings.py +++ b/openbb_platform/providers/sec/openbb_sec/models/etf_holdings.py @@ -310,7 +310,6 @@ class SecEtfHoldingsFetcher( **kwargs: Any, ) -> Dict: """Return the raw data from the SEC endpoint.""" - filing_candidates = pd.DataFrame.from_records( get_nport_candidates(symbol=query.symbol, use_cache=query.use_cache) ) |