Skip to content

Commit

Permalink
Disable 429 specific rate limiting until Retry-After is available
Browse files Browse the repository at this point in the history
  • Loading branch information
Mike committed Dec 13, 2023
1 parent 9ce9106 commit c253cbb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 1 addition & 2 deletions src/hdx/api/configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
import requests

from . import __version__
from .remotehdx import RemoteHDX
from hdx.utilities.dictandlist import merge_two_dictionaries
from hdx.utilities.email import Email
from hdx.utilities.loader import load_json, load_yaml
Expand Down Expand Up @@ -475,7 +474,7 @@ def setup_session_remoteckan(
full_agent=self.get_user_agent(), **kwargs
)
if remoteckan is None:
self._remoteckan = RemoteHDX(
self._remoteckan = ckanapi.RemoteCKAN(
self.get_hdx_site_url(),
user_agent=user_agent,
session=self._session,
Expand Down
4 changes: 3 additions & 1 deletion src/hdx/api/remotehdx.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
"""Connection to HDX with rate limiting"""
"""Connection to HDX with rate limiting
Currently unused awaiting HDX server to add Retry-After header
"""
import logging
from time import sleep

Expand Down

0 comments on commit c253cbb

Please sign in to comment.