Open Bug 1506782 Opened 2 years ago Updated 1 year ago

Replace `about:newtab` like page for Fennec and GeckoView with `about:blank`

Categories

(Testing :: Marionette, task, P3)

Unspecified
Android
task

Tracking

(Not tracked)

People

(Reporter: whimboo, Unassigned)

References

(Blocks 2 open bugs)

Details

(Whiteboard: [geckoview:p3])

On bug 1506643 I set the `browser.newtabpage.enabled` pref to false to prevent loading the `about:newtab` page when opening new tabs. I would like to see something similar for Fennec, which also shows such a page, but the preference from above doesn't seem to be related.

James, mind telling me how this page can be disabled? Thanks.
Flags: needinfo?(snorp)
I don't really have knowledge of how this works in the Fennec UI. Someone on Susheel's team should be able to help.
Flags: needinfo?(snorp) → needinfo?(sdaswani)
As a P3 this will show up in triage at some point.
Flags: needinfo?(sdaswani)
(In reply to :sdaswani only needinfo from comment #2)
> As a P3 this will show up in triage at some point.

No, because this bug is not part of the Fennec product but Marionette. As such it won't appear in any triage you do.
Flags: needinfo?(sdaswani)
Sorry - can you help me with priority here? What does this work block, and how important is it?
Flags: needinfo?(sdaswani)
With this work I want to make navigation for Marionette tests more reliable, and faster. The tests don't need the `about:newtab` experience including activity stream, but only have to open `about:blank`.

The only information needed here is how to turn off activity stream so that just `about:blank` gets loaded when opening new tabs.
Flags: needinfo?(sdaswani)
Liz how can we prioritize this against our other Fennec needs?
Flags: needinfo?(sdaswani) → needinfo?(lhenry)
Probably pretty easy to do, and it's good to improve automated test reliability - why not make it a P2. Vlad can your team take a look?
Flags: needinfo?(lhenry) → needinfo?(vbacia.work)
Priority: P3 → P2
I actually don't understand why we make it such a complicated process from just a question about which preference to use to display `about:blank` and not the activity stream in Fennec. Is there no such preference yet?

Again, this is not a bug for Fennec but Marionette and as such any whiteboard/severity setting doesn't apply.
Priority: P2 → P3

So I found that through the setting I can set the home page to "about:blank", and to let Fennec use it for each new tab. But I have problems figuring out how Marionette could set it, because those don't seem to be preferences.

Both are android:key entries here:

https://searchfox.org/mozilla-central/rev/227f5329f75bd8b16c6b146a7414598a420260cb/mobile/android/app/src/main/res/xml/preferences_home.xml#14,20

Where are those preferences set? James, could you please help? Thanks

Flags: needinfo?(snorp)

We weren't able to get this done via bug 1533058, because of the following call:

tab = this.tabBrowser.addTab(null);

Usually it would allow to pass in about:blank as URL, but as jgraham said null was necessary to use for GeckoView to kill the race condition. I haven't further investigated yet, but I hope that with being able to set the above preferences that we won't need neither of those.

Type: enhancement → task
Whiteboard: [geckoview:p3]
OS: Unspecified → Android

Parachuting into this conversation. In general there's a big split between App-level settings and Gecko-level settings, and in general Mozilla's Apps (Fennec, Fenix, r-b, etc) don't have a uniform way to manage App-level settings in automation. I have considered writing harness code to set Android SharedPreferences (which is what :whimboo is ultimately referring to in #c9), but it's very fiddly and requires either support from within Marionette/Gecko or the App or to have android:debuggable="true".

I have had success adding per-App Intent arguments to control these types of things from automation: e.g., https://github.com/mozilla-mobile/fenix/issues/1525.

For this particular issue, in my browsertime harness, I use the "skipstartpane" extra for Fennec and launch with a URL before driving Marionette: see https://searchfox.org/mozilla-central/search?q=EXTRA_SKIP_STARTPANE&redirect=false for the Intent argument.

Yeah, comment #11 captures the problem -- an intent argument is a good way to add this kind of thing to Fennec.

Flags: needinfo?(snorp)

This bug should also cover GeckoView given that Fennec goes away soon. So I assume that an intent argument will also work with GeckoView based browsers?

Summary: Replace `about:newtab` like page for Fennec tests with `about:blank` → Replace `about:newtab` like page for Fennec and GeckoView with `about:blank`

(In reply to Henrik Skupin (:whimboo) [⌚️UTC+2] from comment #13)

This bug should also cover GeckoView given that Fennec goes away soon. So I assume that an intent argument will also work with GeckoView based browsers?

Each product would need special attention, but yes, it's possible -- GV doesn't have any role in this.

You need to log in before you can comment on or make changes to this bug.