Closed Bug 1561676 Opened 7 months ago Closed 7 months ago

WebSocket panel crashes in WebConsole

Categories

(DevTools :: Console, defect, P2)

defect

Tracking

(firefox69 fixed)

RESOLVED FIXED
Firefox 69
Tracking Status
firefox69 --- fixed

People

(Reporter: christoph-wa, Assigned: tanhengyeow)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:69.0) Gecko/20100101 Firefox/69.0

Steps to reproduce:

  1. Enable 'Requests' in WebConsole
  2. Select request which is a WebSocket connection
  3. Select 'WebSocket' Tab

Actual results:

   {
  "id": "server1.conn2.netEvent892",
  "actor": "server1.conn2.netEvent892",
  "level": "log",
  "isXHR": false,
  "request": {
    "url": "https://s-usc1c-nss-210.firebaseio.com/...",
    "method": "GET",
    "headersSize": 515
  },
  "response": {
    "httpVersion": "HTTP/1.1",
    "status": "101",
    "statusText": "Switching Protocols",
    "headersSize": 254,
    "remoteAddress": "2600:1901:0:94b6::",
    "remotePort": 443,
    "content": {
      "mimeType": "text/plain"
    },
    "bodySize": 0,
    "transferredSize": 254
  },
  "source": "network",
  "type": "log",
  "groupId": null,
  "timeStamp": 1561571288618,
  "indent": 0,
  "updates": [
    "requestHeaders",
    "requestCookies",
    "responseStart",
    "eventTimings",
    "securityInfo",
    "responseHeaders",
    "responseCookies",
    "responseContent"
  ],
  "openedOnce": true,
  "securityInfo": null,
  "requestHeadersFromUploadStream": null,
  "private": false,
  "url": "https://s-usc1c-nss-210.firebaseio.com/....",
  "urlDetails": {
    "baseNameWithQuery": "...",
    "host": "s-usc1c-nss-210.firebaseio.com",
    "scheme": "https",
    "unicodeUrl": "https://s-usc1c-nss-210.firebaseio.com/....",
    "isLocal": null,
    "url": "https://s-usc1c-nss-210.firebaseio.com/.,,"
  },
  "method": "GET",
  "cause": {
    "type": "websocket",
    "loadingDocumentUri": "file:///Users/christophwalch...",
    "stacktraceAvailable": false
  },
  "lastExecutionPoint": {
    "point": {
      "checkpoint": 0,
      "progress": 0
    },
    "messageCount": 12
  }
}

console.error: (new TypeError("state.webSockets is undefined", "resource://devtools/client/netmonitor/src/selectors/web-sockets.js", 8))

@Heng Yeow: can you please take a look at this?

Honza

Flags: needinfo?(E0032242)

The WebSocketsPanel reaches out to the netmonitor's state to fetch WebSocket frames for display in the panel.

I believe the state is not available in the console panel when WebSocketsPanel is displayed through the console, thus the error. After discussion with @nchevobbe through Slack, the consensus was to not show WebSocketsPanel in the console panel for now until we figure out a good solution to get the data in the WebSocketsPanel. Will be submitting a patch for this.

Flags: needinfo?(E0032242)

Hide WebSocketsPanel in console.

Assignee: nobody → E0032242
Status: UNCONFIRMED → NEW
Ever confirmed: true
Priority: -- → P2
Status: NEW → ASSIGNED
Pushed by jodvarko@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/89d1a2584683
WebSocket panel crashes in WebConsole. r=nchevobbe,Honza
Status: ASSIGNED → RESOLVED
Closed: 7 months ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 69
You need to log in before you can comment on or make changes to this bug.