From 56751188774506e307e1c91ac1a304358240adfe Mon Sep 17 00:00:00 2001 From: JustAnotherArchivist Date: Tue, 14 Jul 2020 05:42:06 +0000 Subject: [PATCH] Rename id to id_ to avoid clash with builtin --- qwarc/__init__.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/qwarc/__init__.py b/qwarc/__init__.py index 90e0c9d..3e0968c 100644 --- a/qwarc/__init__.py +++ b/qwarc/__init__.py @@ -374,15 +374,15 @@ class QWARC: else: # Really nothing to do anymore break - id, itemType, itemValue, status = result - cursor.execute('UPDATE items SET status = ? WHERE id = ?', (STATUS_INPROGRESS, id)) + id_, itemType, itemValue, status = result + cursor.execute('UPDATE items SET status = ? WHERE id = ?', (STATUS_INPROGRESS, id_)) session = self._freeSessions.popleft() item = self._make_item(itemType, itemValue, session, DEFAULT_HEADERS) task = asyncio.ensure_future(item.process()) #TODO: Is there a better way to add custom information to a task/coroutine object? task.taskType = 'process' - task.id = id + task.id = id_ task.itemType = itemType task.itemValue = itemValue task.item = item