Skip to content
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

revisit: browser.urlbar.maxRichResults #125

Closed
Thorin-Oakenpants opened this issue May 22, 2017 · 24 comments
Closed

revisit: browser.urlbar.maxRichResults #125

Thorin-Oakenpants opened this issue May 22, 2017 · 24 comments

Comments

@Thorin-Oakenpants
Copy link
Contributor

@nodiscc says (pyllyukko/user.js@116d986#commitcomment-22223673)

  • =12: when typing a URL in the address bar, a maximum of 12 bookmarks or history items are suggested in the dropdown below the URL bar
  • =0: nothing is shown in the dropdown

So I propose setting up a definitive test with steps to be reproduced, with screenshots of results, to be used in vanilla Firefox. I can test this on Windows. I would think that crssi, earthlng and my own results from earlier testing in which we all found browser.urlbar.autocomplete.enabled = 0 did not hide any history-bookmark-opentab suggestions was good.

But to be sure, and to check the behavior is not different in linux, let's document it properly.

@earthlng
Copy link
Contributor

earthlng commented May 22, 2017

The commit is about browser.urlbar.maxRichResults, isn't it?
browser.urlbar.autocomplete.enabled does autocomplete on the urlbar when you type something. It's also a boolean type pref and setting it to 12 or any other integer in the user.js will result in an error I assume.

@crssi
Copy link

crssi commented May 22, 2017

browser.urlbar.autocomplete.enabled name is somehow wrong, since when this is false, the search actually doesn't work.

EDIT: and I have not seen that when true any auto complete would do some magic, except that the search works

@earthlng
Copy link
Contributor

browser.urlbar.autocomplete.enabled name is somehow wrong, since when this is false, the search actually doesn't work.

Can confirm. Weird! Thanks for pointing that out mate!

and I have not seen that when true any auto complete would do some magic

If I type in a "g" for example then it autocompletes to ghacks.net for me, because I have ghacks.net in either my bookmarks or history and it has the most "points" so to speak. The points are accumulated based on the "bonuses" from places.frecency.*Bonus. If I wanted "g" to autocomplete to github.com for example I could reload github.com in a normal window a couple times until its bonuses are higher than ghacks.net.

@Thorin-Oakenpants Thorin-Oakenpants changed the title revisit: browser.urlbar.autocomplete.enabled revisit: browser.urlbar.maxRichResults May 22, 2017
@crssi
Copy link

crssi commented May 22, 2017

and more than 10 also didn't make sense

@earthlng
Copy link
Contributor

earthlng commented May 22, 2017

We tested it in FF52 at the time I think, maybe they fixed it again in FF53 idk.
Can you test and set it to 1 or something other than 10 or 0 and see if it only shows 1?
nvm, just tested in FF53.0.3 and 1 doesn't limit it to only 1, so it's not really honored completely.

@crssi
Copy link

crssi commented May 22, 2017

I have the same setting as I had here #63 (comment)
and the results are the same... 0 does not disable it at all, tested just now.

@nodiscc
Copy link

nodiscc commented May 22, 2017

I get the same results as @Thorin-Oakenpants in his tests above, in Firefox 45.9.0 ESR (Debian).

@earthlng
Copy link
Contributor

No, I'm using my main FF but I have the 3 browser.urlbar.suggest.* prefs you listed above set to true by default and maxrich doesn't do shit here

@earthlng
Copy link
Contributor

earthlng commented May 22, 2017

your main FF has the 3 browser.urlbar.suggest.* prefs disabled though, right? 0850c

@earthlng
Copy link
Contributor

Ok so with a copy of my FF53 profile in a portable FF53 and with all my addons removed, I still get the same results i.e. maxrich is ignored. browser.urlbar.autocomplete.enabled;false however stops the dropdown completely. I'll try to figure out how to get an EXACT match with maxrich.

@earthlng
Copy link
Contributor

earthlng commented May 22, 2017

With maxrich=0 it works for some characters but not for others. for example "a", "b", "c" all only show the visit with/search with, but "g" and "h" shows some entries. And it's the same in my main FF.
Something in the places file seems to influence how many entries are shown. Maybe something to do with the bonuses I mentioned above. Try typing a single "h" then keep typing for http, it shows a number of (randomly picked?) entries out of all my bookmarks and/or history. Really weird.

edit: yeah, most likely something to do with the bonuses because it's always my most visited pages that are displayed and seem to overwrite maxrich=0

edit2: you can test this yourself. set maxrich to 10 and find an entry that's listed last, then open that page in a NORMAL window and reload the site a couple times until it's listed at the top, then set maxrich=0 and see if you reached the bonuses required to overwrite maxrich=0

edit3: there's a test file that tests for "frecency" (bonuses) in relation to maxrich. It also sets 2 hidden prefs that could have something to do with the behavior we noticed (line 219+)

@crssi
Copy link

crssi commented May 22, 2017

same as @earthlng and I also didn't do any css customs

@earthlng
Copy link
Contributor

earthlng commented May 22, 2017

So if you use PB a lot, chances are that none of your bookmarks or history will have high bonuses and therefore maxrich=0 seems to work correctly but if you do have entries with high bonuses then maxrich=0 is ignored for those entries. That's my working theory right now and unless someone can proof otherwise, I think that's what we're witnessing here

@earthlng
Copy link
Contributor

earthlng commented May 22, 2017

But I think we should comment out browser.urlbar.autocomplete.enabled because as @crssi mentioned the search "keywords" don't work otherwise. That's not the same as keyword.enabled;false btw. - the search keywords still work regardless of keyword.enabled

How do you search Pants? since you seem to use browser.urlbar.autocomplete.enabled;false.
I guess typing "s midget porn" in the urlbar and pressing enter doesn't work for you? (assuming you have a search engine bound to the keyword "s" of course)

@earthlng
Copy link
Contributor

WTF is "keywords"

Options > Search > there you can define "keywords" for use in the urlbar for every search engine

@crssi
Copy link

crssi commented May 22, 2017

I don't use keywords.
But did a test your observation now... funny if you set in user.js
user_pref("browser.urlbar.suggest.bookmark", false);
user_pref("browser.urlbar.suggest.openpage", false);

and after those you do:
user_pref("browser.urlbar.autocomplete.enabled", true);

The both browser.urlbar.suggest. are preserved to false even that autocomplete is set to true.

@earthlng
Copy link
Contributor

I have no keywords in any of my custom search engines

you should try it. Makes it a lot easier to search directly where you want to search. Fe. I have "y" for youtube, "s" for startpage, "x" for ixquick, "w" for wikipedia etc

@earthlng
Copy link
Contributor

So I think we can need to do something with 0850a (urlbar*) and 0850c (*suggest) - merge them.

or remove 0850a because it seems to be the master switch and will be toggled automatically depending on 0850c

@earthlng
Copy link
Contributor

You'll have to explain how to do the bonuses thingy.

I already did but okay let me try again. Assuming you still have the github pages in your test profile history/bookmarks that you pictured above. The last one in that list is "Learn how developers build software" so now you load that page over and over again until it makes it to the top of the dropdown list. Now that history entry will have a pretty high "frecency". Maybe do this for 2 or 3 pages that were previously at the bottom of the list. Now set maxrich=0 and type "g" or "git" again - if my theory is correct those pages should now get listed and effectively ignore maxrich=0.

@earthlng
Copy link
Contributor

They all have a visit count of 1 at the moment.

It's not the visit count that matters. One of my bookmarks that always shows up in the dropdown even with maxrich=0 has a visit count of 0!

@earthlng
Copy link
Contributor

earthlng commented May 22, 2017

Afaik, PB doesn't update the bonuses unless you bookmark a page I think (EDIT: don't take my word for it - I only assume it doesn't because PB also doesn't store anything in History!). Look at places.*Bonus in about:config. Idk when each one of those triggers but if you don't want the bonuses you can set all of those prefs to 0 and reset the "frecency" columns in places.sqlite.
I guess when you wipe the history, a lot of it will be cleared as well. Idk how it all works exactly just that it exists and that it determines influences what gets listed and what doesn't

is this a bug?

How should I know? :)

@earthlng
Copy link
Contributor

earthlng commented May 22, 2017

how the F do you add a keyword to a search engine

right there in Options > Search -> double click the "keyword" column and type in a keyword. It can be a single letter or a string (numbers should also work, idk about other chars like underline or shit like that).
You can't define these in the xml file itself AFAIK - once you set them in the Options they are stored in search.json.blabla

Thorin-Oakenpants referenced this issue in pyllyukko/user.js May 22, 2017
As discussed in #208

The URL suggestion is controlled by browser.urlbar.autocomplete.enabled
@Atavic
Copy link

Atavic commented May 22, 2017

 * HOWEVER, items (bookmarks/history etc) with a high "frequency"/"bonus" will always
 * be displayed (no we do not know how these are calculated or what the threshold is).

That's the "Frecency" score that defines urls that should appear in the drop-down:

places.frecency.*

@Atavic
Copy link

Atavic commented May 22, 2017

No, it's a fast/deep telemetry thing. I do not like it as its monitoring times are set at various ranges from minutes up to months.

Thorin-Oakenpants added a commit that referenced this issue May 23, 2017
clarifies usage of maxRichResults and cases of aberrant number of items displayed
@arkenfox arkenfox deleted a comment from Atavic Jun 14, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

5 participants