1
0
mirror of https://github.com/webrecorder/pywb.git synced 2025-03-15 00:03:28 +01:00

Fix dedup_index_url configuration option (#617)

The 'dedup_index_url' configuration option should be inside the
'recorder' section.
This commit is contained in:
Lukey3332 2021-04-27 05:52:58 +02:00 committed by GitHub
parent 7ce4573c70
commit cdb17c4000
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -78,7 +78,7 @@ class WarcServer(BaseWarcServer):
recorder_config = self.config.get('recorder') or {}
if isinstance(recorder_config, dict) and recorder_config.get('dedup_policy'):
self.dedup_index_url = self.config.get('dedup_index_url', WarcServer.DEFAULT_DEDUP_URL)
self.dedup_index_url = recorder_config.get('dedup_index_url', WarcServer.DEFAULT_DEDUP_URL)
if self.dedup_index_url and not self.dedup_index_url.startswith('redis://'):
raise Exception("The dedup_index_url must start with \"redis://\". Only Redis-based dedup index is supported at this time.")
else: