Hi all,
We've struck a problem when using remote queries and hoping someone can
offer some guidance. I haven't managed to get a C++ reproduction in the
test suite, but I have got a demo that fails using Python:
import xapian
db = xapian.remote_open('localhost', 8100)
qp = xapian.QueryParser()
qp.set_database(db)
query = qp.parse_query('test')
enq = xapian.Enquire(db)
enq.set_query(query)
enq.get_mset(0, 10)
This script fails with:
xapian.InvalidArgumentError: REMOTE:Bad serialised query
I've tracked it down to api/omqueryinternal.cc, in QUnserial::readquery(),
and is the 2nd occurance of that error message in that function (ie, inside
the "case '['" block). It appears that the check for:
if (p == end)
throw Xapian::InvalidArgumentError("Bad serialised query");
works fine when a "compound" query is used, but incorrectly fails with
a
simple query that uses a single term. The script above will work if you
change the search string to 'test and foo', for example.
This is happening on the subversion trunk, on Windows. I've thus far failed
to get xapian building on my Ubuntu 6.1 installation, and as the Windows
port of the remote code doesn't exist for any official xapian releases,
I'm
unable to check where else the bug exists - but I find it very unlikely the
bug is platform specific.\
Please let me know if there is any other information you need, or if I can
otherwise help with this.
Cheers,
Mark