Skip to content
This repository has been archived by the owner on Jan 17, 2023. It is now read-only.

Investigate "Invalid tab ID" #2990

Open
ianb opened this issue Jun 7, 2017 · 6 comments
Open

Investigate "Invalid tab ID" #2990

ianb opened this issue Jun 7, 2017 · 6 comments
Labels
code Code quality issue, that does not have any outward effect on the product firefox Something that has to ship in the add-on in Firefox P2 ✿sentry✿ Something related to an error report in our Sentry error collector
Milestone

Comments

@ianb
Copy link
Contributor

ianb commented Jun 7, 2017

In this Sentry report:

Async*executeModules/</lastPromise<@moz-extension://7fe0f050-1d76-4c7f-ac76-6b876d972c65/background/selectorLoader.js:86:16
promise callback*executeModules/<@moz-extension://7fe0f050-1d76-4c7f-ac76-6b876d972c65/background/selectorLoader.js:85:21
executeModules@moz-extension://7fe0f050-1d76-4c7f-ac76-6b876d972c65/background/selectorLoader.js:84:5
promise callback*exports.toggle@moz-extension://7fe0f050-1d76-4c7f-ac76-6b876d972c65/background/selectorLoader.js:128:12
promise callback*toggleSelector@moz-extension://7fe0f050-1d76-4c7f-ac76-6b876d972c65/background/main.js:62:12
promise callback*forceOnboarding@moz-extension://7fe0f050-1d76-4c7f-ac76-6b876d972c65/background/main.js:122:12
@moz-extension://7fe0f050-1d76-4c7f-ac76-6b876d972c65/background/main.js:114:22
promise callback*@moz-extension://7fe0f050-1d76-4c7f-ac76-6b876d972c65/background/main.js:107:9
watchFunction/<@moz-extension://7fe0f050-1d76-4c7f-ac76-6b876d972c65/catcher.js:52:16

I'm pretty sure this is a case where the tab is closed while the selector is still loading. Adding a little delay to the script loading would probably make this easy to reproduce.

We might want to catch and ignore this particular error.

@SoftVision-CosminMuntean

A similar error was reported in issue #2842, but the issue was fixed and I haven't managed to reproduce it with the provided steps on the latest Nightly build with Screenshots 9.0.0 installed.

However, on the latest Screenshots (9.0.0) version I have found other steps that shows an "Invalid tab ID" error in browser console:

[Prerequisites]:

  • Have the latest Nightly (2017-06-07) build with Screenshots 9.0.0 installed and create a new profile.

[Steps to reproduce]:

  1. Open latest Nightly build with the profile from prerequisites and open the browser console (CTRL+SHIFT+J).
  2. Click the "Screenshots" icon from browser toolbar. (the Onboarding tour is displayed)
  3. Open a new tab.
  4. Focus the tab from step 2 where the onboarding tour is displayed.
  5. Close the tab and observe the browser console.

[Expected Results]:

  • No error is displayed in browser console.

[Actual Results]:

  • A "Invalid tab ID:" is displayed in browser console.

[Notes]:

  • Here is a screen recording with the issue:
    invalid tab 1

@ghost ghost added the ✿sentry✿ Something related to an error report in our Sentry error collector label Jun 8, 2017
@ghost ghost added this to the Screenshots in 55 milestone Jun 8, 2017
@ghost ghost added the firefox-55 label Jun 8, 2017
@ianb ianb self-assigned this Jun 8, 2017
ianb added a commit that referenced this issue Jun 8, 2017
The code always tries to make the icon not-active, but one case when it tries is when the tab has been closed
@ianb
Copy link
Contributor Author

ianb commented Jul 10, 2017

This seems mostly gone, but reappeared in this report:

resource://screenshots-addon/background/selectorLoader.js in Async*executeModules/</lastPromise< at line 86:16
resource://screenshots-addon/background/selectorLoader.js in promise callback*executeModules/< at line 85:21
resource://screenshots-addon/background/selectorLoader.js in executeModules at line 84:5
resource://screenshots-addon/background/selectorLoader.js in promise callback*exports.toggle at line 127:12
resource://screenshots-addon/background/main.js in promise callback*startSelectionWithOnboarding at line 85:12
resource://screenshots-addon/background/main.js at line 301:12
resource://screenshots-addon/background/communication.js in exports.onMessage< at line 25:16
resource://screenshots-addon/catcher.js in watchFunction/< at line 54:16
resource://screenshots-addon/background/startBackground.js at line 67:14
resource://screenshots-addon/background/startBackground.js in promise callback* at line 66:5

@ianb ianb reopened this Jul 10, 2017
@ianb ianb removed their assignment Jul 11, 2017
@jaredhirsch
Copy link
Member

Hopefully #3222 will fix this as well...

@ghost ghost modified the milestones: General Release 55, General Release 57 Aug 1, 2017
@johngruen johngruen added P2 and removed firefox-56 labels Aug 17, 2017
@ghost ghost added the firefox Something that has to ship in the add-on in Firefox label Sep 21, 2017
@ghost ghost modified the milestones: General Release 57, Launch 58 Sep 22, 2017
@johngruen johngruen modified the milestones: Bucket ☕️, Sprint 1 (59-0) Oct 31, 2017
@chenba
Copy link
Collaborator

chenba commented Nov 20, 2017

The last comment's from almost four months ago. Is this still an issue?

@SoftVision-CosminMuntean

I have tested this issue using the STR from the second comment on latest Nightly (59.0a1) build and the issue is no longer reproducible.
So, I think that the issue was fixed.

@ghost ghost modified the milestones: Sprint 1 (59-0) 🍷, Backlog Nov 27, 2017
@ianb ianb added the code Code quality issue, that does not have any outward effect on the product label Jan 10, 2018
@patrickdark
Copy link

Is this bug only applicable to the screenshots API or Firefox in general? I'm able to reproduce it without using the screenshots API at all; it inexplicably appears after I successfully close a tab using browser.tabs.remove at the end of a promise chain.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
code Code quality issue, that does not have any outward effect on the product firefox Something that has to ship in the add-on in Firefox P2 ✿sentry✿ Something related to an error report in our Sentry error collector
Projects
None yet
Development

No branches or pull requests

6 participants