-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Recoll WebUI returns 0 results when search folder other than <all> is chosen #23
Comments
Hi, I'll assume that you are using Recoll 1.19.9 as .19 is not yet there :) The query encoding seems wrong on the failing query: there should be some "%2F" pieces for the / separators. Is this a github effect or are they really missing when printed on the terminal ? An initial try at reproducing this failed (I do get a correctly encoded query and results), but I can try harder once I know that the / characters are really missing. GET /results?query=sac&dir=d%2Fdir+with+blanks&after=&before=&sort=relevancyrating&ascending=0&page=1 HTTP/1.1" |
Oops... version from the future! I did my best to read the webui code that generates the query, but my python isn't very strong. I ran diff against the webui.py that's in the zip & what is running on my machine and the files are identical. Is there a debug flag I can set to create more verbose logging for you? The query string I posted for the webui was from stdout, which seems to be where the app sends its logging info. |
This is weird. In the query, there should be slash characters encoded as %2F. Instead, they seem to be suppressed. In other terms, "dir=mw-ksbENG+Doc+ControlDOCs" should look like "dir=mw-ksb%2FENG+Doc+Control%2FDOCs" instead (and the capitalization of "DOCs" is weird too by the way). I think that it would be interesting to have a look at the generated HTML by using "show page source". I am especially interested by the "folders" section, the part which looks like:
(Put the data between 2 lines with 4 backquotes to prevent interpretation by GitHub, have a look at the "Markdown" link above). |
Oo! The capitalization in "DOCs" is correct--that's how the directory is named, for whatever reason. Looking at your example HTML, I wonder if this has anything to do with this index being of a CIFS share mounted on a Windows file server...? Here's the source of the page after searching for "balance" with 0 results returned, from the same directory as in my original post. I fouled up the names of the folders, but kept any spaces or special characters that were present in the original folder names. The only non letters there were are ( ) - . and _
|
On a whim, I partially tested the CIFS theory by indexing a local directory. The resulting folder list has a distinctly different visual appearance than that of my CIFS-share directories. Each separate dir has its own line with only its name listed, rather than the concatenation of its name as well as its parents back to root. Tomorrow, i'll map up a LUN to the recoll machine and copy my index target over so it's stored locally in ext4. I suspect that everything will work as expected... |
The / characters are definitely missing. I would like to try and reproduce this, it would make a resolution easier. Could you please tell me precisely how the CIFS share is mounted ? I tried with a vanilla autofs mount and things look normal... |
I'm not sure I understand what sort of information you'd like, so let me know if I'm missing something. The CIFS mount only includes _netdev,ro and is mounted to a mountpoint on /. As far as what is being served, it's a Windows 2008 R2 FileSharing server sharing at full network permissions and full NTFS permissions for the user I'm using to mount it. |
Thanks, I was wondering if you could have been using a fuse-based mount. I'll try to reproduce the issue, but I currently have trouble getting Fedora 20 to behave as a Virtualbox guest. |
Ok, I can reproduce the problem. I can try to see what happens and look for a possible fix now. |
Ok, I think it's fixed. This had nothing to do with the kind of system actually, just the fact that the top dir was directly under root (/). There is a fixed file here: https://github.com/medoc92/recoll-webui/blob/master/webui.py Please let me know how this works for you and I'll put up a pull request. Cheers, jf |
Sorry for the delay--github seems to have ceased notifying me of updates to this thread... Fantastic! It's fixed! Now, a related question: are the subdirectories supposed to be listed out one after another, or is there supposed to be some sort of visual or treed organization to show the parent/child relationship? What I'm seeing in the dropdown is just a pure list of each directory name, sorted like this: If the above is confusing, it lists all the level 1 directories first, then the level 2 afterward, then 3 & so on. |
Looks to be a browser specific problem! I get just a straight, non-indented pile of words from the following versions: However, it does display correctly in Firefox 22.0 (running on Win 7) and 25.0 (Running on Fedora). Also on FF ESR 10.0.5 (Running on Centos). Writing for multiple browsers must be miserable! |
Yes, it must be awful, happily enough, I'm more of a desktop programmer... Anyway, while koniu seems to be away, I have changed the identation method to something ugly but which should work on all browsers (hopefully). The modified file is here: I'll create a pull request, but I really hope that a nicer solution can be found... |
Assuming this is fixed. Thanks medoc |
Sorry for my delay in replying, guys--I'll apply this patch and report back. |
Fixed! Thank you guys for your help. This thing is a masterpiece! |
Hi! Marvelous work on this project, I just discovered recoll & webui and am absolutely delighted at its power.
I discovered something odd today, though, while using the webUI: when constraining the search scope to a subdirectory (rather than ), the search will return 0 results, in every case, in every directory. The Recoll search GUI itself will return expected results.
Searching for the same term from will properly find the search terms, even from within the directories that return 0 when searched exclusively.
I've reinstalled both, just in case there was a problem there somewhere, but the problem is easily duplicated.
I'm using Fedora 20 x64, Recoll 1.19.19 + Xapian 1.2.15. WebUI version was whatever was up on January 18th, about 12 GMT. The web browser is Firefox 25.0. I also tried it in chrome 32.0.1700.76 m with the same results.
The searched material is on a CIFS share mounted on the Fedora machine. WebUI is started from the same account that owns the index (non-root).
Here is a comparison of a search for "balance" in a folder called ENG Doc Control/Docs. The base of the searched directories is mw-ksb.
recoll query:
(((balance:(wqf=11) OR balancing OR balanced OR balancer OR balances OR balancers) AND (XP PHRASE 4 XPmw-ksb PHRASE 4 XPENG Doc Control PHRASE 4 XPDOCs)))
webui query:
"GET /results?query=balance&dir=mw-ksbENG+Doc+ControlDOCs&after=&before=&sort=relevancyrating&ascending=0&page=1 HTTP/1.1" 200 9665
The web query in this example returned 0 results, while the Recoll UI, which was constrained to the same subfolder, returned 239.
Here's what the webUI returns when set to for the same search term:
"GET /results?query=balance&dir=%3Call%3E&after=&before=&sort=relevancyrating&ascending=0&page=1 HTTP/1.1" 200 70209
Please let me know if I can provide more information. Your help is greatly appreciated!
The text was updated successfully, but these errors were encountered: