Closed Bug 1173900 Opened 9 years ago Closed 9 years ago

Home tab isn't initialized after clearing private data and pressing show introduction

Categories

(Firefox for iOS :: Browser, defect)

Other
iOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED
Tracking Status
fxios - ---

People

(Reporter: bmunar, Unassigned, Mentored)

Details

(Whiteboard: [good first bug][lang=swift])

Attachments

(1 file)

47 bytes, text/x-github-pull-request
rnewman
: review+
sleroux
: feedback+
Details | Review
Repeat these steps
1. go into settings and clear private data
2. click show introduction again
3. click start browsing

you will get an empty page and either a 0 or 1 in the tab icon. If you click it, it will sometimes crash. Quite a weird bug.
Mentor: rnewman
Whiteboard: [good first bug][lang=swift]
Any other way to reproduce this? Otherwise I think pass on v1
It reproduced twice (100%) on my iPhone 6 simulator.

After step 1,2(click "Show Tour"),3. It stay in a status the last page url appears in url bar with a blank page and the tab icon shows 1. If I click it, it crashed with the following log:

2015-07-08 15:45:15.081 Client[5176:508685] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: 'attempt to scroll to invalid index path: <NSIndexPath: 0xc000000000010016> {length = 2, path = 0 - 2}'
*** First throw call stack:
(
	0   CoreFoundation                      0x0000000110a1cc65 __exceptionPreprocess + 165
	1   libobjc.A.dylib                     0x000000010ff44bb7 objc_exception_throw + 45
	2   CoreFoundation                      0x0000000110a1cb9d +[NSException raise:format:] + 205
	3   UIKit                               0x0000000111bfb7ba -[UICollectionView scrollToItemAtIndexPath:atScrollPosition:animated:] + 213
	4   Client                              0x000000010e649e1e _TFC6Client17TabTrayController21transitionablePreShowfS0_FTPS_14Transitionable_7optionsCS_17TransitionOptions_T_ + 750
	5   Client                              0x000000010e64a99a _TToFC6Client17TabTrayController21transitionablePreShowfS0_FTPS_14Transitionable_7optionsCS_17TransitionOptions_T_ + 74
	6   Client                              0x000000010e6e35b0 _TFC6Client17TransitionManager17animateTransitionfS0_FPSo36UIViewControllerContextTransitioning_T_ + 2048
	7   Client                              0x000000010e6e3ad6 _TToFC6Client17TransitionManager17animateTransitionfS0_FPSo36UIViewControllerContextTransitioning_T_ + 54
	8   UIKit                               0x00000001116dfa0e __56-[UIPresentationController runTransitionForCurrentState]_block_invoke + 1867
	9   UIKit                               0x00000001115f55ec _applyBlockToCFArrayCopiedToStack + 314
	10  UIKit                               0x00000001115f5466 _afterCACommitHandler + 533
	11  CoreFoundation                      0x000000011094fca7 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 23
	12  CoreFoundation                      0x000000011094fc00 __CFRunLoopDoObservers + 368
	13  CoreFoundation                      0x0000000110945a33 __CFRunLoopRun + 1123
	14  CoreFoundation                      0x0000000110945366 CFRunLoopRunSpecific + 470
	15  GraphicsServices                    0x0000000114339a3e GSEventRunModal + 161
	16  UIKit                               0x00000001115d18c0 UIApplicationMain + 1282
	17  Client                              0x000000010e61cdf5 main + 997
	18  libdyld.dylib                       0x00000001171da145 start + 1
	19  ???                                 0x0000000000000001 0x0 + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
before step 1. You should open two or more pages...
Attached file Pull request
Attachment #8630919 - Flags: review?(rnewman)
Comment on attachment 8630919 [details] [review]
Pull request

It's a fix, and it's fine, but I don't understand why it works. So a second set of eyes, please :)
Attachment #8630919 - Flags: review?(sleroux)
Attachment #8630919 - Flags: review?(rnewman)
Attachment #8630919 - Flags: review+
Comment on attachment 8630919 [details] [review]
Pull request

Left a comment on the PR about why this works and what we should do to fix it.
Attachment #8630919 - Flags: feedback+
Yup looks like this fixes that issue as well :D
Do we have an updated PR (just running into this again while testing today)
(In reply to Aaron Train [:aaronmt] from comment #10)
> Do we have an updated PR (just running into this again while testing today)

Sorry for I am quite busy these days. May have an updated PR in two days.
I have updated the PR. More comments on Github.

Sorry for the delay caused by my relocation to a new city.
(In reply to Stephan Leroux [:sleroux] from comment #8)
> Yup looks like this fixes that issue as well :D

That issue is not stable reproducible which I think is more tough..
Once we iron out the issues with https://bugzilla.mozilla.org/show_bug.cgi?id=1184678, do you think that this will be resolved? I remember testing a patch you had put up earlier and it seemed to resolve this bug.
Flags: needinfo?(zhaocong89)
(In reply to Stephan Leroux [:sleroux] from comment #14)
> Once we iron out the issues with
> https://bugzilla.mozilla.org/show_bug.cgi?id=1184678, do you think that this
> will be resolved? I remember testing a patch you had put up earlier and it
> seemed to resolve this bug.

I think the patch you tested is for solving bug. I get hands on fixing bug 1184678 after this bug.
 
This bug is focus on "clicking the tabs number button(right to the urlbar) after clear private" but the bug 1184678 is focus on "Default(suggested sites) Tiles not shown on TopSitesPanel after tour(it happens when the app is first installed with nearly 100% probability)".
Flags: needinfo?(zhaocong89)
This is fixed! (i think)
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Attachment #8630919 - Flags: review?(sleroux)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: