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

[dev 5569] Tree structure is messed up after session restore #1513

Closed
SXZ1 opened this issue Nov 8, 2017 · 5 comments
Closed

[dev 5569] Tree structure is messed up after session restore #1513

SXZ1 opened this issue Nov 8, 2017 · 5 comments

Comments

@SXZ1
Copy link

SXZ1 commented Nov 8, 2017

Win 8.1, Nightly 07-11-17
Looks like that's a fallout from this commit 4b89bfd
STR: (not optimized and quite complex, I'll try to simplify it tomorrow)
Create new profile, install TST dev https://piro.sakura.ne.jp/xul/xpi/nightly/treestyletab-we.xpi
Close Nightly, launch Nightly
Go to github.com in the active tab
Ctrl-click Features 8 times
Press Ctrl-9, ctrl-click Pricing 10 times
Press Ctrl-8, ctrl-click Marketplace 10 times
Press Ctrl-6, ctrl-click Explore 10 times
Press Ctrl-4, ctrl-click Business 10 times
Press Ctrl-T, go to github.com, ctrl-click Business 4 times
Look at the 1st stack from the top, look at its child tabs, you need the 9th child tab from the top (see comparison before/after), left-click on it
Wait 10 sec, close-launch Nightly

AR: tree structure is messed up, before/after:
5569
I would like to point out I pressed left mouse button slowly when reproducing the STR in order to make sure there is no race condition. However, you can press mouse button quickly if you want, bug is reproduced in both cases. Surprisingly, I couldn't reproduce the bug when I opened just one stack so you do need to press Ctrl-4,6,8 and fill those stacks with tabs.

@piroor
Copy link
Owner

piroor commented Nov 9, 2017

I couldn't reproduce this problem. This seems to be fixed by recent commits.

@SXZ1
Copy link
Author

SXZ1 commented Nov 9, 2017

Unfortunately, I can still reproduce this bug in 5592 but here is simplified STR:

Install TST dev, close-launch Nightly
Go to github.com in the active tab
Ctrl-click Features, press Ctrl-2, ctrl-click Explore, Marketplace, Pricing
Press Ctrl-T 20 times, press Ctrl-4
Wait 10 sec, close-launch Nightly, restore session

AR: Active tab got removed from the stack, order of tabs and tree structure are messed up, before/after:
5569

Also, I've reproduced all steps from STR slowly in order to make sure there is no race condition but you can execute all steps quickly, bug is reproduced in both cases.

@XCanG
Copy link

XCanG commented Nov 9, 2017

I have similar issue, but in my case tree strucrure shifted to next element.
Example structure before exit:

tab1
tab2
  tab21
  tab22
  tab23
    tab231
tab3
  tab31
tab4

After restore:

tab1
tab2
tab21
  tab22
  tab23
  tab231
    tab3
tab31
  tab4

Nightly used latest version available in a day, i.e. today it Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:58.0) Gecko/20100101 Firefox/58.0 ID:20171108110838
treestyletab used from mozilla addons site (2.0.7)

@piroor
Copy link
Owner

piroor commented Nov 9, 2017

@SXZ1 This problem sometimes happen, sometimes doesn't happen on my environment. By something timing issue, TST seems to fail to detect restored status of the recycled tab. Because there is no specific feature to track the event "a tab is restored" in WebExtensions APIs, I think TST can do nothing anymore for this problem...

@XCanG Yours seems different from the main topic of this issue. This issue mainly discussing about the case: Firefox is configured to start with just home page or a blank page, and you restore the last session from the hamburger menu => "Restore Previous Sessin" manually. On the other hand, your case is about "Options" => "General" => "When Nightly (Firefox) starts" => "Show your windows and tabs from last time". In your case, TST just restores tree structure from their position, so I think it can be triggered by a hidden tab placed before the tab1.

@SXZ1
Copy link
Author

SXZ1 commented Nov 9, 2017

@piroor thank you! The only thing I can suggest is try this new STR that I've just used to reproduce this bug two times in a row. The only change compared to previous STR is that you have to press Ctrl-T 30 times instead of 20 (marked in bold):

Install TST dev, close-launch Nightly
Go to github.com in the active tab
Ctrl-click Features, press Ctrl-2, ctrl-click Explore, Marketplace, Pricing
Press Ctrl-T 30 times, press Ctrl-4
Wait 10 sec, close-launch Nightly, restore session

@SXZ1 SXZ1 closed this as completed Nov 10, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants