Let local debugger clients find the DebuggerServerConnection

RESOLVED FIXED in Firefox 24

Status

RESOLVED FIXED
6 years ago
4 months ago

People

(Reporter: dcamp, Assigned: dcamp)

Tracking

unspecified
Firefox 24
x86
Mac OS X
Bug Flags:
in-testsuite +

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Assignee)

Description

6 years ago
Created attachment 757019 [details] [diff] [review]
v1

This shouldn't be too easy or common, but there are a few cases where we want to get to the server side of a debugger connection from the client.  There's at least one test that tries to do that, we're going to need it while we convert the inspector, and Firebug does it.

This puts a reference to the DebuggerServerConnection on the client's local transport object.  I also updated the test that pokes through _connections.
Attachment #757019 - Flags: review?(past)
Comment on attachment 757019 [details] [diff] [review]
v1

Review of attachment 757019 [details] [diff] [review]:
-----------------------------------------------------------------

How about a big fat warning in a comment somewhere that if you are using the server connection from the client, you are probably doing it wrong?
Attachment #757019 - Flags: review?(past) → review+
(Assignee)

Comment 2

6 years ago
Comment on attachment 757019 [details] [diff] [review]
v1

Yeah, I can add that.
(Assignee)

Comment 3

6 years ago
Adding the following comment:

    // I'm putting this here because I trust you.
    //
    // There are times, when using a local connection, when you're going
    // to be tempted to just get direct access to the server.  Resist that
    // temptation!  If you succumb to that temptation, you will make the
    // fine developers that work on Fennec and Firefox OS sad.  They're
    // professionals, they'll try to act like they understand, but deep
    // down you'll know that you hurt them.
    //
    // This reference allows you to give in to that temptation.  There are
    // times this makes sense: tests, for example, and while porting a
    // previously local-only codebase to the remote protocol.
    //
    // But every time you use this, you will feel the shame of having
    // used a property that starts with a '_'.
(Assignee)

Comment 5

6 years ago
https://hg.mozilla.org/integration/fx-team/rev/94cae09bda18
Assignee: nobody → dcamp
Whiteboard: [fixed-in-fx-team]
https://hg.mozilla.org/mozilla-central/rev/94cae09bda18
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Whiteboard: [fixed-in-fx-team]
Target Milestone: --- → Firefox 24

Updated

4 months ago
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.