Description

If the xapian search is enabled, the Macro FullSearchCached / FullSearch acting different (comparing to the MoinMoin Search) for "category searches". In MoinMoin you'll find a syntax like:

<<FullSearchCached(category:MoinMoinBugs/1.6.3FullSearchWithXapianForCategory)>>
or
<<FullSearchCached(category:CategoryLinux)>>
or
<<FullSearchCached(cat:CategoryLinux)>>

http://master16.moinmo.in/CategoryTemplate?action=raw

With Xapian enabled only a search without the Category Name is working. Don't be sure; maybe it's because it's only searching for in fulltext mode!

<<FullSearchCached(cat:Linux)>>

<!> An other side effect (of not supporting category:CategoryLinux) is that the Form/Wikipage FindPage is not working for Category Searching.

Url with categories=CategoryApache:

FindPage?action=fullsearch&advancedsearch=1&and_terms=&or_terms=&not_terms=&mtime=&categories=CategoryApache&language=&mimetype=

Steps to reproduce

Use Xapian and see that Category Search with FullSearch and FindPage is not possible!

Example

FullSearch

Category Search

http://lotek.heavy.ch/CategoryTest

Attachment

screenshot.png

Logfile if you call this page above:

2008-05-06 15:59:50,754 INFO request.find_remote_addr: addrs == ['83.78.138.141', '127.0.0.1']
2008-05-06 15:59:50,807 INFO xapianSearch: query = 'Xapian::Query(XCAT:linux)'
2008-05-06 15:59:51,241 INFO xapianSearch: query = 'Xapian::Query(XCAT:linux)'
2008-05-06 15:59:51,674 INFO xapianSearch: query = 'Xapian::Query(XCAT:categorylinux)'
2008-05-06 15:59:51,678 INFO xapianSearch: query = 'Xapian::Query(XCAT:categorylinux)'

FindPage

FindPage

http://lotek.heavy.ch/FindPage

Attachment

FindPage_screenshot.png

Logfile if you try to search for CategoryApache with the FindPage:

2008-05-06 16:01:09,767 INFO request.find_remote_addr: addrs == ['83.78.138.141', '127.0.0.1']
2008-05-06 16:01:09,774 INFO xapianSearch: query = 'Xapian::Query(XCAT:categoryapache)'

Component selection

Details

MoinMoin Version

1.6.3 included changeset 2642 fc9439999597 hg.moinmo.in

OS and Version

RedHat Linux

Python Version

2.5.2

Server Setup

Apache WSGI

Server Details

Language you are using the wiki in (set in the browser/UserPreferences)

Workaround


I installed the latest "changeset 2643 3376df1919e3" and after that your patch. First also needed to rebuilding the Index (without it wasn't working). The xapian search now only accepting the correct syntax "cat:CategoryLinux". The old syntax "cat:Linux" is not working anymore. (Test for FullSearch or Results of FindPage).

Another Problem is, that if you use some german CategoryName like "Kategorie" it seems not to work (maybe like to test under http://rock.heavy.ch/KategorieNews

config file:

page_category_regex = u'^Kategorie[A-Z]'

-- MarcelHäfner 2008-05-07 07:12:22


Needs more work:

Discussion

So I'm on 1.8.5 and after switching to Xapian, if a page linked to a category with brackets, like [[CategoryABCStuff]], the !CategoryABCStuff page doesn't list it. I am not clear from the above discussion what is the proper workaround for 1.8.5? Has this problem really remained unfixed since 1.6.3? Should this page be renamed to reflect that it's still a bug in 1.8.5? -- JohnGoerzen 2009-10-16 21:38:17

I'm using the default regex on a fresh install. -- JohnGoerzen 2009-10-26 20:30:01

Plan


CategoryMoinMoinBugFixed

MoinMoin: MoinMoinBugs/1.6.3FullSearchWithXapianForCategory (last edited 2009-11-27 11:58:57 by ReimarBauer)