UnboundLocalError: local variable 'i' referenced before assignment

Issue #431 resolved
Rahul Shrivastava
created an issue

After completing index, when I am doing search I am getting following error,

File "/Users/rahul/.virtualenvs/search2/lib/python2.7/site-packages/whoosh/query/compound.py", line 226, in _tree_matcher

subms = [q.matcher(searcher, context) for q in subs]

File "/Users/rahul/.virtualenvs/search2/lib/python2.7/site-packages/whoosh/query/terms.py", line 211, in matcher

qs = [Term(fieldname, word) for word in self._btexts(reader)]

File "/Users/rahul/.virtualenvs/search2/lib/python2.7/site-packages/whoosh/codec/base.py", line 364, in find_matches

match = dfa.next_valid_string(term)

File "/Users/rahul/.virtualenvs/search2/lib/python2.7/site-packages/whoosh/automata/fsa.py", line 272, in next_valid_string

stack.append((string[:i + 1], state, None))

Comments (2)

  1. Log in to comment