question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Incorrect size metrics when using chunked responses

See original GitHub issue

We’re seeing random numbers reported for imageSize, cssSize and jsSize. We are suspecting this to be caused by all a missing Content-Length since they are chunked.

This seems to be an upstream issue and fixed in PhantomJS ariya/phantomjs#13834 and ariya/phantomjs#13195 both waiting for merge.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:9 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
tiwilliamcommented, Mar 29, 2016

I built my own binary from ariya/phantomjs#13834 and it sure fixes my issue:

$ /usr/local/bin/phantomas --no-externals --allow-domain=tictail.com,marketplace.ttcdn.co https://tictail.com | egrep "(jsSize|cssSize|imageSize)"
* cssSize: 187303 bytes
* jsSize: 1072063 bytes
* imageSize: 936359 bytes

$ /usr/local/bin/phantomas --no-externals --allow-domain=tictail.com,marketplace.ttcdn.co https://tictail.com | egrep "(jsSize|cssSize|imageSize)"
* cssSize: 187303 bytes
* jsSize: 1072063 bytes
* imageSize: 936359 bytes

$ /usr/local/bin/phantomas --no-externals --allow-domain=tictail.com,marketplace.ttcdn.co https://tictail.com | egrep "(jsSize|cssSize|imageSize)"
* cssSize: 187303 bytes
* jsSize: 1072063 bytes
* imageSize: 936359 bytes
0reactions
macbrecommented, Jul 10, 2016

@tiwilliam - thanks for submitting a patch to PhantomJS

@AdriwanKenoby - I guess we need to wait for https://github.com/ariya/phantomjs/pull/13834

Read more comments on GitHub >

github_iconTop Results From Across the Web

How HTTP Chunked Encoding Was Killing a Request - DZone
The ChunkedFileStreamResult class looked like a class that was created to be able to return a Transfer-Encoding: chunked result to the client.
Read more >
Issue with Chunked Transfer Encoding in HTTP Response
What steps will reproduce the problem? 1. I'm sending a response from my server with chunked transfer encoding
Read more >
"too many transfer encodings" 502 chunked response errors ...
The error described in this KB occurs if any response from an application has multiple transfer-encoding headers, either directly adding or a ...
Read more >
Content-Length header versus chunked encoding
The downside of chunked encoding is the small overhead of adding the chunk size before each chunk and the download progress bar. Any...
Read more >
Transferring Payload in Multiple Chunks (Chunked Upload ...
Perform a chunked upload to authenticate requests using the HTTP authorization ... You can send data in fixed size or variable size chunks....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found