Commit 4c1c0641 authored by Jean-Francois Dockes's avatar Jean-Francois Dockes
Browse files

Adapt to recoll api change: fetchone and fetchmany dont raise exceptions at...

Adapt to recoll api change: fetchone and fetchmany dont raise exceptions at the end of the list any more, but return none/empty (be more like pep249)
parent 1f40006d
......@@ -240,6 +240,11 @@ def recoll_search(q, dosnippets=True):
for i in range(config['perpage']):
try:
doc = query.fetchone()
# Later Recoll versions return None at EOL instead of
# exception This change restores conformance to PEP 249
# Python Database API Specification
if not doc:
break
except:
break
d = {}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment