if 'localhost' is unset in /etc/hosts about:debugging doesn't allow the debugging of an addon

NEW
Unassigned

Status

()

Firefox
Developer Tools: about:debugging
P3
normal
a year ago
10 months ago

People

(Reporter: baku, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

a year ago
I know, this is a corner case, but I was debugging an addon with a friend of mine, and on his computer, 'localhost' was not defined in /etc/hosts (don't ask why).
When we clicked on 'debug' the addon in about:debugging, instead asking the permission for connecting FF to a debugging port, an empty window has been shown, with no content in it.
Probably we should consider the use of '127.0.0.1' instead of 'localhost'.
Component: Developer Tools → Developer Tools: about:debugging
Product: Developer Documentation → Firefox
This is driven by the pref devtools.debugger.chrome-debugging-host (which indeed defaults to localhost). Note that changing it in about:config will not impact the pref used when starting the addon toolbox, so we can't use that as a workaround.

This default value for this preference is set at http://searchfox.org/mozilla-central/rev/b0e1da2a90ada7e00f265838a3fafd00af33e547/devtools/client/preferences/debugger.js#12

127.0.0.1 should work on any machine that supports IPv4, so I guess we could update the default (maybe a fallback mechanism would be better, try first localhost, then fallback on 127.0.0.1 ; but probably not worth it?)
Priority: -- → P3
Summary: if 'localhost' is unset in /etc/hosts about:debugger doesn't allow the debugging of an addon → if 'localhost' is unset in /etc/hosts about:debugging doesn't allow the debugging of an addon
You need to log in before you can comment on or make changes to this bug.