Skip to content

Commit

Permalink
Merge pull request #117 from hllywluis/dev
Browse files Browse the repository at this point in the history
[Bugfix] Actually remove failed imports
  • Loading branch information
ManiMatter committed Jun 4, 2024
2 parents e14d041 + f7d966a commit 38d1eba
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/jobs/remove_failed_imports.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ async def remove_failed_imports(settingsDict, BASE_URL, API_KEY, NAME, deleted_d

if queueItem['status'] == 'completed' \
and queueItem['trackedDownloadStatus'] == 'warning' \
and queueItem['trackedDownloadState'] == 'importPending':
and (queueItem['trackedDownloadState'] == 'importPending' or queueItem['trackedDownloadState'] == 'importFailed'):

for statusMessage in queueItem['statusMessages']:
if not settingsDict['FAILED_IMPORT_MESSAGE_PATTERNS'] or any(any(pattern in message for pattern in settingsDict['FAILED_IMPORT_MESSAGE_PATTERNS']) for message in statusMessage.get('messages', [])):
Expand Down

0 comments on commit 38d1eba

Please sign in to comment.