diff --git a/kentik_api_library/kentik_api/analytics/flatness.py b/kentik_api_library/kentik_api/analytics/flatness.py index c63462e8..5695fd8b 100644 --- a/kentik_api_library/kentik_api/analytics/flatness.py +++ b/kentik_api_library/kentik_api/analytics/flatness.py @@ -359,7 +359,7 @@ def flatness_analysis( :param data: DataFrame indexed by time ("ts" column) containing columns "link" and "bytes_out" or "bps_out. "link" column is expected to contain names of network links as : "bytes_out" columns (if present) is expected to contain total number of bytes transmitted via the link - "bps_out" column (if present) is expected to contain average outbound bandwith in bits/s for the link + "bps_out" column (if present) is expected to contain average outbound bandwidth in bits/s for the link For "bytes_out" and "bps_out" the value is for a time period ending at the timestamp. If the "bps_out" column is present it is used as the source for the analysis (regardless of presence of "bytes_out") @@ -374,7 +374,7 @@ def flatness_analysis( log.debug("Computing bandwidth via each link") if not has_uniform_datetime_index(data): resolution = min_index_resolution(data).total_seconds() - log.info("Retrieved data have non-uniform sampling (min resolution: %f seconds) - resampling") + log.info("Retrieved data have non-uniform sampling (min resolution: %f seconds) - resampling", resolution) data = resample_volume_data(data, f"{resolution}S") link_bw = compute_link_bandwidth(data) else: diff --git a/kentik_api_library/kentik_api/api_connection/retryable_session.py b/kentik_api_library/kentik_api/api_connection/retryable_session.py index b0222c2a..0c542592 100755 --- a/kentik_api_library/kentik_api/api_connection/retryable_session.py +++ b/kentik_api_library/kentik_api/api_connection/retryable_session.py @@ -6,12 +6,13 @@ log = logging.getLogger(__name__) + # mypy: ignore-errors class RetryableSession(Session): DEFAULT_RETRY_STRATEGY = Retry( total=3, backoff_factor=1, - status_forcelist=[429, 500, 502, 503, 504], + status_forcelist=[429, 502, 503, 504], allowed_methods=["DELETE", "HEAD", "GET", "PUT", "OPTIONS", "PATCH", "POST"], ) diff --git a/kentik_api_library/setup.py b/kentik_api_library/setup.py index 52edf762..ce380c64 100644 --- a/kentik_api_library/setup.py +++ b/kentik_api_library/setup.py @@ -102,7 +102,7 @@ def run(self): url="https://github.com/kentik/community_sdk_python/tree/main/kentik_api_library", license="Apache-2.0", include_package_data=True, - install_requires=["dacite>=1.6.0", "requests>=2.25.0", "typing-extensions>=3.7.4.3"], + install_requires=["dacite>=1.6.0", "requests[socks]>=2.25.0", "typing-extensions>=3.7.4.3", "urllib3>=1.26.0"], setup_requires=["pytest-runner", "pylint-runner", "setuptools_scm", "wheel"], tests_require=["httpretty", "pytest", "pylint"], extras_require={