Skip to content

Commit

Permalink
fix: add more forgiving timeout duration for sdn backup
Browse files Browse the repository at this point in the history
  • Loading branch information
christopappas committed Dec 18, 2024
1 parent 0999877 commit 3a45fc9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def handle(self, *args, **options):
# download the CSV locally, to check size and pass along to import
threshold = options['threshold']
url = settings.CONSOLIDATED_SCREENING_LIST_URL
timeout = settings.SDN_CHECK_REQUEST_TIMEOUT
timeout = settings.SDN_BACKUP_REQUEST_TIMEOUT

with requests.Session() as s:
try:
Expand Down
1 change: 1 addition & 0 deletions sanctions/settings/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ def root(*path_fragments):

# SDN Check
SDN_CHECK_REQUEST_TIMEOUT = 5 # Value is in seconds.
SDN_BACKUP_REQUEST_TIMEOUT = 15 # Value is in seconds.
# Settings to download the government CSL
CONSOLIDATED_SCREENING_LIST_URL = 'https://data.trade.gov/downloadable_consolidated_screening_list/v1/consolidated.csv'
# Settings to check government purchase restriction lists
Expand Down

0 comments on commit 3a45fc9

Please sign in to comment.