Ticket #440 (closed defect: fixed)

Opened 7 months ago

Last modified 7 months ago

Compact tests fail on Win32 for Flint database

Reported by: charliejuggler Owned by: olly
Priority: normal Milestone: 1.0.18
Component: Test Suite Version: 1.0.17
Severity: normal Keywords:
Cc: Blocked By:
Operating System: Microsoft Windows Blocking:

Description (last modified by olly) (diff)

Full test log attached. No other tests fail (i.e. on the other databases)

Running test: compactnorenumber1...The system cannot find the path specified.
 DatabaseOpeningError: Couldn't detect type of database
Running test: compactmerge1...The system cannot find the path specified.
 DatabaseOpeningError: Couldn't detect type of database
Running test: compactmultichunks1...The system cannot find the path specified.
 DatabaseOpeningError: Couldn't detect type of database

Attachments

test_fail.txt Download (8.7 KB) - added by charliejuggler 7 months ago.
Test log
patch1.patch Download (2.0 KB) - added by charliejuggler 7 months ago.
Patch to make xapian-compact tests work on Windows

Change History

Changed 7 months ago by charliejuggler

Test log

Changed 7 months ago by richard

It's probably a problem with the .exe extension. eg, in api_compact.cc line 118 we have:

    string cmd = "../bin/xapian-compact >/dev/null 2>&1 --no-renumber ";

Try adding a .exe to that, and see if it works.

We'll probably need to do something a bit more clever to find the paths.

Changed 7 months ago by charliejuggler

Patch to make xapian-compact tests work on Windows

Changed 7 months ago by olly

  • status changed from new to assigned
  • milestone set to 1.1.4

Thanks, marking for 1.1.4.

Changed 7 months ago by olly

  • description modified (diff)
  • milestone changed from 1.1.4 to 1.0.18

Lack of .exe isn't an issue - you definitely can run binaries without an explicit extension.

Added a new compatibility wrapper for sys/wait.h (so we can manage the WEXITSTATUS replacement in a a single place) in r13936, and patched api_compact.cc in r13937.

I reused the XAPIAN_BIN_PATH define we already had rather than duplicating that knowledge here, and I also redirected stderr to nul (with 2>nul which I believe is the right rune). Can you test current trunk?

Needs backporting, so updating milestone.

Changed 7 months ago by charliejuggler

Trunk builds, but unfortunately xapian-compact is crashing when used during test "compactnorenumber1". The following command line is used:

xapian-compact --no-renumber .flint/dbcompactnorenumber1a .flint/dbcompactnorenumber1c .flint/dbwcompactnorenumberout

and it's causing a problem at line 388 of xapian-compact.cc as 'vector subscript out of range'. I have a debug build in the Visual C++ 2008 GUI and the debugger reports: - j,n are zero - used_ranges contains two pairs of ints (5, 1027 and 1028, 1040) - used_ranges_ is empty

Not at all sure what's going on here!

Changed 7 months ago by charliejuggler

Apologies, Trac has eaten some of the formatting above.

xapian-compact --no-renumber .flint/db__compactnorenumber1a .flint/db__compactnorenumber1c .flint/dbw__compactnorenumberout

is the correct command line used.

Changed 7 months ago by olly

OK, this issue should be fixed by r13954. That code is new on trunk, so nothing to backport.

Changed 7 months ago by charliejuggler

Verified as fixed in trunk.

Changed 7 months ago by olly

OK, backported to 1.0 branch in r13962.

Leaving ticket open until this has actually been tested.

Changed 7 months ago by charliejuggler

  • status changed from assigned to closed
  • resolution set to fixed

Tested on the 1.0 branch, closed.

Note: See TracTickets for help on using tickets.