summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDanglewood <85772166+deeleeramone@users.noreply.github.com>2024-01-15 02:21:24 -0800
committerGitHub <noreply@github.com>2024-01-15 10:21:24 +0000
commitc8d555685864e3e5c1d7b1976494577003b8b526 (patch)
tree779bf74fe683edcc21e415d3bdb39e27e344011d
parent83aa71a28bfc75a4ba53e44f71c3af550fc500fc (diff)
hotfix/intrinio-dividends-limit: Fix Limit Param Alias (#5951)
* fix limit param * pylint unused argument, recapture test cassette --------- Co-authored-by: Pratyush Shukla <ps4534@nyu.edu>
-rw-r--r--openbb_platform/providers/intrinio/openbb_intrinio/models/historical_dividends.py5
-rw-r--r--openbb_platform/providers/intrinio/tests/record/http/test_intrinio_fetchers/test_intrinio_historical_dividends_fetcher.yaml10
2 files changed, 8 insertions, 7 deletions
diff --git a/openbb_platform/providers/intrinio/openbb_intrinio/models/historical_dividends.py b/openbb_platform/providers/intrinio/openbb_intrinio/models/historical_dividends.py
index d6ac6769025..582fa8f140b 100644
--- a/openbb_platform/providers/intrinio/openbb_intrinio/models/historical_dividends.py
+++ b/openbb_platform/providers/intrinio/openbb_intrinio/models/historical_dividends.py
@@ -1,5 +1,5 @@
"""Intrinio Historical Dividends Model."""
-
+# pylint: disable=unused-argument
from datetime import datetime
from typing import Any, Dict, List, Optional
@@ -21,10 +21,11 @@ class IntrinioHistoricalDividendsQueryParams(HistoricalDividendsQueryParams):
Source: https://docs.intrinio.com/documentation/web_api/get_security_stock_price_adjustments_v2
"""
+ __alias_dict__ = {"limit": "page_size"}
+
limit: Optional[int] = Field(
default=100,
description=QUERY_DESCRIPTIONS.get("limit", ""),
- alias="page_size",
)
diff --git a/openbb_platform/providers/intrinio/tests/record/http/test_intrinio_fetchers/test_intrinio_historical_dividends_fetcher.yaml b/openbb_platform/providers/intrinio/tests/record/http/test_intrinio_fetchers/test_intrinio_historical_dividends_fetcher.yaml
index e22d63425be..7b3bdc5fbab 100644
--- a/openbb_platform/providers/intrinio/tests/record/http/test_intrinio_fetchers/test_intrinio_historical_dividends_fetcher.yaml
+++ b/openbb_platform/providers/intrinio/tests/record/http/test_intrinio_fetchers/test_intrinio_historical_dividends_fetcher.yaml
@@ -3,17 +3,17 @@ interactions:
body: null
headers:
Accept:
- - '*/*'
+ - application/json
Accept-Encoding:
- - gzip, deflate, br
+ - gzip, deflate
Connection:
- keep-alive
method: GET
- uri: https://api-v2.intrinio.com/securities/AAPL/prices/adjustments?api_key=MOCK_API_KEY&end_date=2023-06-06&limit=100&start_date=2023-01-01
+ uri: https://api-v2.intrinio.com/securities/AAPL/prices/adjustments?api_key=MOCK_API_KEY&end_date=2023-06-06&page_size=100&start_date=2023-01-01
response:
body:
string: !!binary |
- H4sIABJIZmUAA5RRW2vCMBT+KyPPKklr7OVN2ZDB5i7icIwRQhpjtE1Lkg6r+N934gbDvu3xfNdz
+ H4sIAM+MoWUAA5RRW2vCMBT+KyPPKklr7OVN2ZDB5i7icIwRQhpjtE1Lkg6r+N934gbDvu3xfNdz
khNyvhZ71lgtJOPFrnW+ksY7lH+cUMG9RDmKcBQPMR2SCA3QhgtfW5TjUZalE5ImmOKYZgkZoEJ/
6UKaIpDR+G9morVWGtFB1mp5CyGuKbVnlntdo5yM8HnQK4uGBPfLxgmlOE3IhJC4Vxb/q+wTMAky
7UF0QhoyAsC42lm1A4eoq4abjl0YGNhiPZkfn0LW5bXkQWy5UfJH4A6K1cdHm3UgMLwKV0ybppQ3
@@ -27,7 +27,7 @@ interactions:
Content-Type:
- application/json
Date:
- - Tue, 28 Nov 2023 20:05:38 GMT
+ - Fri, 12 Jan 2024 19:02:39 GMT
Transfer-Encoding:
- chunked
Vary: