Skip to content

fix compatibility with Xapian 2#627

Open
ojwb wants to merge 2 commits intosup-heliotrope:developfrom
ojwb:xapian2
Open

fix compatibility with Xapian 2#627
ojwb wants to merge 2 commits intosup-heliotrope:developfrom
ojwb:xapian2

Conversation

@ojwb
Copy link

@ojwb ojwb commented Mar 9, 2026

The updated code still works with Xapian 1.4.x, but not Xapian 1.2.x. Xapian 1.2.x is long unsupported (final release was 2017-09-26) so make 1.4.0 the minimum requirement. Xapian 1.4.0 requires Ruby 2.1 which also seems unlikely to be controversial so require that too.

ojwb added 2 commits March 9, 2026 13:30
The updated code still works with Xapian 1.4.x, but not Xapian 1.2.x.
Xapian 1.2.x is long unsupported (final release was 2017-09-26) so
make 1.4.0 the minimum requirement.  Xapian 1.4.0 requires Ruby 2.1
which also seems unlikely to be controversial so require that too.
@danc86
Copy link
Member

danc86 commented Mar 9, 2026

Thanks for the PR. I didn't even realise there was a 2.0 release of Xapian!

Indeed, now that I have a look I can see that it's not even actually released yet. The first step would be to get nixpkgs updated so that the tests can be run against Xapian 2.0 but it's not in nixpkgs yet either, presumably because it's not actually released.

Also, for the time being I was intending on keeping code to support back to Ruby 2.0 for RHEL7/CentOS7, at least until it becomes too burdensome. So I would prefer to keep some fallback paths that will continue to work with Xapian 1.2.

@ojwb
Copy link
Author

ojwb commented Mar 9, 2026

Xapian 2 is currently at the second release candidate stage but the final release is very close, perhaps even this week. I've been preparing experimental Debian packages and the Debian CI showed these broke the sup-mail package (https://ci.debian.net/packages/s/sup-mail/unstable/amd64/69257796/ if you have a Debian salsa login; I think it's not public thanks to the AI bot onslaught). I took a look in case it was a Xapian problem and saw the fix was easy so it seemed worth offering a patch. FWIW when applied to the Debian package it builds with Xapian2 and tests pass.

CentOS 7 seems to be well past end of support - https://wiki.centos.org/FAQ(2f)General.html#What_is_the_support_.27.27end_of_life.27.27_for_each_CentOS_release.3F says its end of life was 2004-06-30.

Xapian 1.2.x is long unsupported, but if you really want to keep supporting it you can still switch to commit() (added in 1.1.0) but you would need to conditionally use NumberValueRangeProcessor there.

@danc86
Copy link
Member

danc86 commented Mar 9, 2026

Got it, thanks.

I'll leave this PR open for now, and will re-visit it later when Xapian 2.0 is released and has made it into nixpkgs.

@danc86
Copy link
Member

danc86 commented Mar 9, 2026

... unless the NumberRangeProcessor is available in 1.4.x, in which case I can update now in preparation for 2.0 when it comes out later?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants