Closed Bug 1213650 Opened 9 years ago Closed 9 years ago

Reloading (F5) loads about:blank instead of current page

Categories

(Core :: DOM: Navigation, defect)

Unspecified
All
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla45
Tracking Status
e10s m8+ ---
firefox44 --- affected
firefox45 --- fixed

People

(Reporter: alice0775, Assigned: mconley)

References

Details

(Keywords: qawanted, regression)

Attachments

(4 files, 2 obsolete files)

Buid Identifier:
https://hg.mozilla.org/mozilla-central/rev/d1bb0de19476541cd517ab14017e7fedbd9f13e3
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:44.0) Gecko/20100101 Firefox/44.0 ID:20151010030234

It is annoyance bug.

Reproducible: very often , after launch browser

Steps To Reproduce:
1. Copy a url https://bugzilla.mozilla.org/attachment.cgi?id=8672350 to clipboard
2. Start Nightly
3. Right click location bar and chose "Paste & Go"
   (Perform as early as possible after UI available)
4. Wait to load the page
5. Click Reload button

Actual Results:
Reloading (F5) loads about:home instead of current page

Expected Results:
Reloading (F5) should load current page
OS: Unspecified → Windows 7
URL of Comments#0 is not restricted. 
I can reproduce on http://reader.livedoor.com/reader/ and other.
s/about:home/about:blank/
Summary: Reloading (F5) loads about:home instead of current page → Reloading (F5) loads about:blank instead of current page
Regression window:
https://hg.mozilla.org/integration/fx-team/pushloghtml?fromchange=5161d574297a1fbd0fba5fa91fbe14f186e996e4&tochange=76a433881e4b

Regressed by: 
76a433881e4b	Dave Townsend — Bug 1175267: When a load redirected to a new process is cancelled restore the existing content.
Blocks: 1175267
Flags: needinfo?(dtownsend)
Keywords: regression
I can also reproduce in ubuntu,
OS: Windows 7 → All
Flags: needinfo?(dtownsend)
Dave, looks like your regression. What do you want to do?
Flags: needinfo?(dtownsend)
following str, I'm not reproducing on Windows.
Keywords: qawanted
I encountered this several times. Nightly just starts with that firstrun page, and it takes long time to load (even to connect). While the page is still completely white, I sometimes manage to paste URL (I use mozregression to test some web pages) and press enter - that exposes this bug.

STR:
1. Create "user.js" in your profile folder with the line:
>  user_pref("browser.startup.homepage_override.mstone", "41.0.2");
2. Enable e10s, restart the browser if needed
3. Copy url of this bug
4. Restart the browser
5. When you see the browser window opened, repeat the following several times:
   Ctrl+L -> Ctrl+V -> Ctrl+Enter
(until you see the page with this bug loading). Ctrl in "Ctrl+Enter" isn't required - it just helps to perform keypresses faster. Also, if you have applications like Autohotkey, you can try binding all those 3 pressings to another shortcut (to perform those 3 pressings even faster).

@Alice: I believe Ctrl+L -> Ctrl+V -> Ctrl+Enter is faster than STR that involves context menu...
        Can you reproduce the issue using my steps?
 Of course I forgot Steps 6 & 7:
6. Wait to load the page
7. Click Reload button
(In reply to arni2033 from comment #8)

> 
> @Alice: I believe Ctrl+L -> Ctrl+V -> Ctrl+Enter is faster than STR that
> involves context menu...
>         Can you reproduce the issue using my steps?

Yes, I can reproduce with  Ctrl+L -> Ctrl+V -> Ctrl+Enter
(In reply to Brad Lassey [:blassey] (use needinfo?) from comment #6)
> Dave, looks like your regression. What do you want to do?

At this point I don't know what we can do other than backing out the original patch and trying to figure out a new approach. The feature bug 1175267 may not be something we care about supporting in the future, a question for Kev really.
Flags: needinfo?(dtownsend)
Assignee: nobody → mconley
Hey Alice, I'm having reproducing this with the STR you've given. Are you able to reproduce it with a clean profile? I'm wondering if perhaps you have a home page or session store setting that I'm missing.
Flags: needinfo?(alice0775)
(In reply to Mike Conley (:mconley) - Needinfo me! from comment #12)
> Hey Alice, I'm having reproducing this with the STR you've given. Are you
> able to reproduce it with a clean profile? I'm wondering if perhaps you have
> a home page or session store setting that I'm missing.

I can reproduce with newly created profile(home page and session store setting are all default).
Flags: needinfo?(alice0775)
I've tried with a new profile as well, and here's a screencast of me attempting to reproduce the behaviour:

http://screencast.com/t/yY2IN3dMTHsI

Am I missing a step somehow?
Flags: needinfo?(alice0775)
(In reply to Mike Conley (:mconley) - Needinfo me! from comment #14)
> I've tried with a new profile as well, and here's a screencast of me
> attempting to reproduce the behaviour:
> 
> http://screencast.com/t/yY2IN3dMTHsI
> 
> Am I missing a step somehow?

I think your PC is super fast.

You need to execute "Paste & Go" command before the home page is fully displayed.
Flags: needinfo?(alice0775)
Alright, I'll hunt down a slower machine - thanks.
(In reply to Mike Conley (:mconley) - Needinfo me! from comment #14)
> Am I missing a step somehow?
On a really new profile you must get an annoying firstrun page on first startup. See STR in comment 8. OR, you can try to set that url as homepage.
// I don't know how Alice managed to reproduce that with about:home. My PC appears to be a bit faster

I think that a slow DNS server could probably help (in conjunction with setting some url as homepage)
Okay, finally got this to reproduce.

The profile needs to be configured so that it loads about:home by default on startup. It also helps to use a slow connection (I'm tethering through my phone).

Digging into this now...
Bug 1213650 - Regression test.
So I think I have a solution for this that won't make us back out bug 1175267.

The problem appears to be that if navigateAndRestore doesn't behave too well when called multiple times before the browser has a chance to flush. The loadArguments that are passed into the first call seem to take precedence, and so the content process gets confused about the browser history state.

Attaching a patch shortly, and then I'm hoping either Alice0775 or arni2033 (or both) can test my change to make sure it's actually fixing the problem for them (it does seem to pass my regression test).
Comment on attachment 8688092 [details]
MozReview Request: Bug 1213650 - Regression tests.

Review request updated; see interdiff: https://reviewboard.mozilla.org/r/25289/diff/1-2/
Bug 1213650 - Stash the last value of lastArguments to navigateAndRestore to restore with. r?Mossop
Try build coming in here:

https://treeherder.mozilla.org/#/jobs?repo=try&revision=aafcbe5316c6

Alice0775 - do you think you could try reproducing with this build once it has finished?
Flags: needinfo?(alice0775)
(In reply to Mike Conley (:mconley) - Needinfo me! from comment #23)
> Try build coming in here:
> 
> https://treeherder.mozilla.org/#/jobs?repo=try&revision=aafcbe5316c6
> 
> Alice0775 - do you think you could try reproducing with this build once it
> has finished?

I can still reproduced the problem on the try build.

https://hg.mozilla.org/try/rev/aafcbe5316c65a6199973d9f56b727a4531b389e
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Firefox/45.0 ID:20151116144934
Flags: needinfo?(alice0775)
Hrm. That's disappointing. I'll try again on my netbook tomorrow.
Flags: needinfo?(mconley)
Comment on attachment 8688092 [details]
MozReview Request: Bug 1213650 - Regression tests.

Review request updated; see interdiff: https://reviewboard.mozilla.org/r/25289/diff/2-3/
Attachment #8688092 - Attachment description: MozReview Request: Bug 1213650 - Regression test. → MozReview Request: Bug 1213650 - Regression tests.
Comment on attachment 8688130 [details]
MozReview Request: Bug 1213650 - Stash the last value of lastArguments to navigateAndRestore to restore with. r?Mossop

Review request updated; see interdiff: https://reviewboard.mozilla.org/r/25291/diff/1-2/
Finally have a test case that reproduces the actual bad behaviour. Looking into solutions now.
Flags: needinfo?(mconley)
(In reply to Mike Conley (:mconley) - Needinfo me! from comment #29)
> https://treeherder.mozilla.org/#/jobs?repo=try&revision=4a0ef4c96304
I was able to reproduce the bug in 4 of ~50 attempts. This happens _much_ less, but still does.

1 of the attempts had different result:
I pasted the link and pressed Enter, but only initial page has loaded. However, when I pressed F5, browser loaded the link I pasted
I saw this strange behavior on m-c too (several times)
So my regression tests still pass even with bug 1175267 backed out, even though I can no longer reproduce the bug with the backout on my netbook. I have to conclude that my test is faulty, but that the backout is fixing the bug.

I will back out bug 1175267 now.
Attachment #8688092 - Attachment is obsolete: true
Attachment #8688130 - Attachment is obsolete: true
(In reply to Mike Conley (:mconley) - Needinfo me! from comment #32)
> I will back out bug 1175267 now.
> https://treeherder.mozilla.org/#/jobs?repo=try&revision=c405d9412f68
I was able to reproduce the bug in 4 of ~30 attempts. It's as hard to reproduce as it was on your previous build. So, I believe that 1175267 only made this behavior easy-to-reproduce (for me).
And your patch seems to made it an edgecase again (because I need perfect timing to reproduce).

I think that 1175267 shouldn't just be backed out (I wonder what Alice will say, if anything)
Flags: needinfo?(mconley)
It's a battle between two edge-cases. :) Bug 1175267 is also an edge-case - this just seems like a worse edge-case.
Flags: needinfo?(mconley)
Just in case: I meant that both these builds expose this bug in ~10% of cases (if I try really hard)
> comment 29: https://treeherder.mozilla.org/#/jobs?repo=try&revision=4a0ef4c96304
> comment 31: https://treeherder.mozilla.org/#/jobs?repo=try&revision=c405d9412f68
Alice0775, do you agree with comment 36?
Flags: needinfo?(alice0775)
The fx-team tinder box build fixes the problem.
https://hg.mozilla.org/integration/fx-team/rev/f622e6d5fd171a3ef6456c393f1617ec9d7eb3a7
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Firefox/45.0 ID:20151118092126

And also, the try build fixes the problem.
https://hg.mozilla.org/try/rev/c405d9412f68893e4ebc495137a8a63cf8bf84d4
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Firefox/45.0 ID:20151117195439
Flags: needinfo?(alice0775)
(In reply to Alice0775 White from comment #38)
> The fx-team tinder box build fixes the problem.
> https://hg.mozilla.org/integration/fx-team/rev/
> f622e6d5fd171a3ef6456c393f1617ec9d7eb3a7
> Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Firefox/45.0
> ID:20151118092126
> 
> And also, the try build fixes the problem.
> https://hg.mozilla.org/try/rev/c405d9412f68893e4ebc495137a8a63cf8bf84d4
> Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Firefox/45.0
> ID:20151117195439

Sorry Alice0775 - I should have been more clear. arni2033 is reporting that the try build at https://treeherder.mozilla.org/#/jobs?repo=try&revision=4a0ef4c96304 fixes the issue (or at least, makes the problem as reproducible as it is with bug 1175267 backed out). Do you see the same thing?
Flags: needinfo?(alice0775)
(In reply to Mike Conley (:mconley) - Needinfo me! from comment #39)
> 
> Sorry Alice0775 - I should have been more clear. arni2033 is reporting that
> the try build at
> https://treeherder.mozilla.org/#/jobs?repo=try&revision=4a0ef4c96304 fixes
> the issue (or at least, makes the problem as reproducible as it is with bug
> 1175267 backed out). Do you see the same thing?

I cannot find the try build of cset 4a0ef4c96304.
Flags: needinfo?(alice0775)
(In reply to Mike Conley (:mconley) - Needinfo me! from comment #41)
> Bah! Sorry - here's the build:
> http://archive.mozilla.org/pub/firefox/try-builds/mconley@mozilla.com-
> c405d9412f68893e4ebc495137a8a63cf8bf84d4/try-win32/firefox-45.0a1.en-US.
> win32.zip


This is same as [1], isn't it. And I had already tested in Comment 38.

[1] comment 31: https://treeherder.mozilla.org/#/jobs?repo=try&revision=c405d9412f68
Flags: needinfo?(alice0775)
Ah, excellent! So my solution actually works! (Insomuch as it puts the likelihood of hitting the bug at about the same probability as from before bug 1175267 landed).

Alright, so my plan:

1) Clean up my fix and get it reviewed
2) Re-land bug 1175267
3) Land this fix
4) File a new bug for the smaller likelihood of hitting this bug (which I believe I have an automated test for)
Bug 1213650 - Regression tests.
Attachment #8689591 - Flags: review?(dtownsend)
Bug 1213650 - Stash the last value of lastArguments to navigateAndRestore to restore with. r?Mossop
Attachment #8689592 - Flags: review?(dtownsend)
Comment on attachment 8689591 [details]
MozReview Request: Bug 1213650 - Regression tests.

https://reviewboard.mozilla.org/r/25661/#review23103

Nice, I think this is related to a failure I had to solve in another bug.
Attachment #8689591 - Flags: review?(dtownsend) → review+
Attachment #8689592 - Flags: review?(dtownsend) → review+
Comment on attachment 8689592 [details]
MozReview Request: Bug 1213650 - Stash the last value of lastArguments to navigateAndRestore to restore with. r?Mossop

https://reviewboard.mozilla.org/r/25663/#review23107
Filed bug 1226657 for the rarer case.
https://hg.mozilla.org/mozilla-central/rev/b97c0c3155ec
https://hg.mozilla.org/mozilla-central/rev/1f9d9bfafd51
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla45
Blocks: 1228179
This problem was not fixed, not improving anything.
I've filed Bug 1213650
Oops I meant Bug 1228179
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: