Open
Bug 1423677
Opened 8 years ago
Updated 3 years ago
Toolbox breaks if the devtools.telemetry.tools.opened.version pref has invalid JSON
Categories
(DevTools :: General, defect, P3)
Tracking
(Not tracked)
NEW
People
(Reporter: majuki, Unassigned)
References
(Blocks 1 open bug)
Details
User Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:57.0) Gecko/20100101 Firefox/57.0
Build ID: 20171128222554
Steps to reproduce:
I go to Tools -> Web Developer -> Inspector (or any similar tool)
Actual results:
A window is opened and nothing is displayed as the last state the tools were in prior to upgrade was detached.
Expected results:
The opening should ignore the attached/detached state and always open attached due to FFQ's new paradigm. In a profile where the last state was attached the tools open normally without any issue.
Comment 1•8 years ago
|
||
Thank you for filing. Let me ask a few questions in order for me to understand the issue better:
> FFQ's new paradigm
Can you define what you mean by new paradigm here?
> The opening should ignore the attached/detached state and always open attached
Do you mean that opening the tools should always open them at the bottom of the browser (docked) instead of remembering the last setting (possibly detached as a new window)?
> A window is opened and nothing is displayed
That sounds like a really bug. So the window got opened but was completely blank?
If you manage to reproduce this issue, could you also open the browser console and see if there are errors in it (you can open it with ctrl+shift+J). If there are errors in there, can you copy them here?
Flags: needinfo?(majuki)
(In reply to Patrick Brosset <:pbro> from comment #1)
> Thank you for filing. Let me ask a few questions in order for me to
> understand the issue better:
>
> > FFQ's new paradigm
> Can you define what you mean by new paradigm here?
From reading issues around lost extensions like Chatzilla it was said that windowed was no longer supported
> > The opening should ignore the attached/detached state and always open attached
> Do you mean that opening the tools should always open them at the bottom of
> the browser (docked) instead of remembering the last setting (possibly
> detached as a new window)?
This is only if what I thought was the cause proves to be valid, which by your reaction it may not be.
> > A window is opened and nothing is displayed
> That sounds like a really bug. So the window got opened but was completely
> blank?
> If you manage to reproduce this issue, could you also open the browser
> console and see if there are errors in it (you can open it with
> ctrl+shift+J). If there are errors in there, can you copy them here?
Always reproducible:
SyntaxError: JSON.parse: unexpected end of data at line 1 column 1 of the JSON data
Stack trace:
logOncePerBrowserVersion@resource://devtools/shared/base-loader.js -> resource://devtools/client/shared/telemetry.js:381:21
_pingTelemetry@resource://devtools/shared/base-loader.js -> resource://devtools/client/framework/toolbox.js:658:5
open/<@resource://devtools/shared/base-loader.js -> resource://devtools/client/framework/toolbox.js:492:7
_run@resource://devtools/shared/base-loader.js -> resource://devtools/shared/task.js:310:39
process@resource://gre/modules/Promise.jsm -> resource://gre/modules/Promise-backend.js:922:23
walkerLoop@resource://gre/modules/Promise.jsm -> resource://gre/modules/Promise-backend.js:806:7
scheduleWalkerLoop/<@resource://gre/modules/Promise.jsm -> resource://gre/modules/Promise-backend.js:742:11
Flags: needinfo?(majuki)
Comment 3•8 years ago
|
||
(In reply to JDev from comment #2)
> > > A window is opened and nothing is displayed
> > That sounds like a really bug. So the window got opened but was completely
> > blank?
> > If you manage to reproduce this issue, could you also open the browser
> > console and see if there are errors in it (you can open it with
> > ctrl+shift+J). If there are errors in there, can you copy them here?
>
> Always reproducible:
>
> SyntaxError: JSON.parse: unexpected end of data at line 1 column 1 of the
> JSON data
> Stack trace:
> logOncePerBrowserVersion@resource://devtools/shared/base-loader.js ->
> resource://devtools/client/shared/telemetry.js:381:21
> _pingTelemetry@resource://devtools/shared/base-loader.js ->
> resource://devtools/client/framework/toolbox.js:658:5
> open/<@resource://devtools/shared/base-loader.js ->
> resource://devtools/client/framework/toolbox.js:492:7
> _run@resource://devtools/shared/base-loader.js ->
> resource://devtools/shared/task.js:310:39
> process@resource://gre/modules/Promise.jsm ->
> resource://gre/modules/Promise-backend.js:922:23
> walkerLoop@resource://gre/modules/Promise.jsm ->
> resource://gre/modules/Promise-backend.js:806:7
> scheduleWalkerLoop/<@resource://gre/modules/Promise.jsm ->
> resource://gre/modules/Promise-backend.js:742:11
Link to the line that's throwing: https://dxr.mozilla.org/mozilla-release/source/devtools/client/shared/telemetry.js#381. It looks like the only consumer of this is in toolbox._pingTelemtry: https://dxr.mozilla.org/mozilla-release/source/devtools/client/framework/toolbox.js#658.
I guess the call to Services.prefs.getCharPref("devtools.telemetry.tools.opened.version") isn't a valid object. Can you see what the value of that preference is in about:config?
Also, we should consider try/catching the JSON.parse call to be safe, since this is in the startup path of the toolbox.
Flags: needinfo?(majuki)
It's an empty string. I changed it long long ago, I guess I never noticed the impact due to using Firebug. The question is, why is Firefox continuing to collect telemetry data when explicitly told not to?
Flags: needinfo?(majuki)
Comment 5•8 years ago
|
||
(In reply to JDev from comment #4)
> It's an empty string. I changed it long long ago, I guess I never noticed
> the impact due to using Firebug. The question is, why is Firefox continuing
> to collect telemetry data when explicitly told not to?
The frontend calls Services.telemetry APIs unconditionally, but they won't send data if you've opted out.
Updated•8 years ago
|
Summary: Web Developer tools broken if the last state prior to 57 was detached → Toolbox breaks if the devtools.telemetry.tools.opened.version pref has invalid JSON
Updated•8 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
Priority: -- → P3
Blocks: dt-telemetry
Updated•7 years ago
|
Product: Firefox → DevTools
Updated•3 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•