Pretty-print WebSocket packets when verbose logging is turned on
Categories
(Remote Protocol :: Agent, enhancement, P1)
Tracking
(firefox74 fixed)
Tracking | Status | |
---|---|---|
firefox74 | --- | fixed |
People
(Reporter: ato, Assigned: ato)
References
(Blocks 1 open bug)
Details
(Whiteboard: [puppeteer-beta-mvp])
Attachments
(2 files, 2 obsolete files)
When remote.log.level
is Log.Level.Info
or above, verbose logging is enabled and we pretty-print JSON payloads to the HTTPD. We should do the same for the JSON payloads that are transmitted across the WebSocket connections.
Assignee | ||
Updated•6 years ago
|
Assignee | ||
Comment 1•6 years ago
|
||
Moving the JSON payload sanitisation function to Protocol.jsm
means we can share it across modules.
The patch also adds new tests.
Assignee | ||
Comment 2•6 years ago
|
||
When remote.log.level is Log.Level.Info or above, verbose logging
is enabled and we pretty-print JSON payloads in requests to the
HTTPD in JSONHandler.
This patch matches the behaviour with JSON payloads being transmitted
across WebSocket connections.
Assignee | ||
Updated•6 years ago
|
Updated•6 years ago
|
Comment 4•6 years ago
|
||
Backed out 2 changesets (Bug 1606612) for 'remote' failures at browser_scriptToEvaluateOnNewDocument.js.
https://hg.mozilla.org/integration/autoland/rev/7835846bfe1b91a1d219ac63cd766d21ceb23fab
Failure log:
https://treeherder.mozilla.org/logviewer.html#/jobs?job_id=283216018&repo=autoland&lineNumber=3930
Assignee | ||
Comment 5•6 years ago
|
||
Certain CDP domains, such as IO.read, rely on returning empty strings.
This removes the filtering of empty strings from JSON payloads so
that return types from the protocol are consistent.
Assignee | ||
Comment 6•6 years ago
|
||
Filtering out empty strings in JSON payloads was not a great idea. Removing that should fix the failing tests.
Updated•6 years ago
|
Updated•6 years ago
|
Assignee | ||
Comment 7•6 years ago
|
||
The CDP protocol expects consistent types to be returned. By filtering
out null values and strings of zero length we break this promise.
Assignee | ||
Comment 8•6 years ago
|
||
(In reply to Andreas Tolfsen ❲:ato❳ from comment #6)
Filtering out empty strings in JSON payloads was not a great idea. Removing that should fix the failing tests.
I’ve reworked the changeset so that we drop this behaviour from JSONHandler
also for consistency.
Comment 10•6 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/d00e6b043f0a
https://hg.mozilla.org/mozilla-central/rev/6b0f8701cfc5
Description
•