init typo
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
subgen_version = '2025.02.60'
|
subgen_version = '2025.02.61'
|
||||||
|
|
||||||
from language_code import LanguageCode
|
from language_code import LanguageCode
|
||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
@@ -125,8 +125,8 @@ docker_status = "Docker" if in_docker else "Standalone"
|
|||||||
class DeduplicatedQueue(queue.Queue):
|
class DeduplicatedQueue(queue.Queue):
|
||||||
"""Queue that prevents duplicates and tracks worker ID."""
|
"""Queue that prevents duplicates and tracks worker ID."""
|
||||||
|
|
||||||
def init(self):
|
def __init__(self):
|
||||||
super().init()
|
super().__init__() # Call the superclass's __init__
|
||||||
self._queued = set()
|
self._queued = set()
|
||||||
self._processing = {} # Store processing tasks by path: {path: worker_id}
|
self._processing = {} # Store processing tasks by path: {path: worker_id}
|
||||||
self._lock = threading.Lock()
|
self._lock = threading.Lock()
|
||||||
@@ -134,7 +134,7 @@ class DeduplicatedQueue(queue.Queue):
|
|||||||
def put(self, item, block=True, timeout=None):
|
def put(self, item, block=True, timeout=None):
|
||||||
with self._lock:
|
with self._lock:
|
||||||
path = item["path"]
|
path = item["path"]
|
||||||
if path not in self._queued : #and path not in self._processing: # Check against the queue
|
if path not in self._queued: #and path not in self._processing: # Check against the queue
|
||||||
super().put(item, block, timeout)
|
super().put(item, block, timeout)
|
||||||
self._queued.add(path)
|
self._queued.add(path)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user