On Sat, 26 Aug 2006, Kevin Ollivier wrote:
My environment: Python 2.4, PyLucene 2.0.0, tested on FC1 and Mac OS X 10.4.7
Intel
I've come across a slightly odd problem, and I'm not sure what I'm doing
wrong. Basically, the issue is that no matter what constant I pass for the
parameter, calls to myIndexReader.getFieldNames() return an empty list. I get
the same results on Linux and Mac OS X, but the test for this feature does
appear to pass just fine, and on top of that, I can query fields in the index
without problems.
Here's a code snippet, where self.indexdir is the directory containing the
PyLucene index:
reader = PyLucene.IndexReader.open(self.indexdir)
info["NumDocs"] = reader.numDocs()
info["Fields"] = reader.getFieldNames(PyLucene.IndexReader.FieldOption.ALL)
Since the test passes, I'm fairly certain I've got a problem in my code
somewhere, but I was wondering if anyone may have come across this behavior
before or knows what kind of mistake could cause it to happen. Aside from
this issue, searching, indexing, etc. seems to work just fine (and I get a
valid value for numDocs() as well).
I've reproduced the problem as described and I'm just as mystified.
Debugging...
Andi..
_______________________________________________
pylucene-dev mailing list
[email protected]
http://lists.osafoundation.org/mailman/listinfo/pylucene-dev