]> git.phdru.name Git - bookmarks_db.git/commitdiff
Feat(Robots): Signal `get_url` is not implemented for forking robots
authorOleg Broytman <phd@phdru.name>
Tue, 10 Sep 2024 16:00:54 +0000 (19:00 +0300)
committerOleg Broytman <phd@phdru.name>
Tue, 10 Sep 2024 16:00:54 +0000 (19:00 +0300)
Robots/concurrent_futures.py

index aa460197e34b49f61528a008db8e26c94b31cc66..b6ab0fb7560b4660464354767c233ba0e9130e9e 100644 (file)
@@ -84,3 +84,7 @@ class cf_multiprocess(concurrent_futures):
     def __init__(self, *args, **kw):
         self.concurrent_class = concurrent.futures.ProcessPoolExecutor
         concurrent_futures.__init__(self, *args, **kw)
+
+    async def get_url(self, url, req_headers):
+        raise NotImplementedError(
+            'This robot does not implement get_url; use non-forking robots.')