Current time: 03-04-2021, 01:52 AM Hello There, Guest! (LoginRegister)

Post Reply 
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
HAR file and HTTP2 - httpversion is wrong
03-04-2016, 06:29 AM
Post: #2
RE: HAR file and HTTP2 - httpversion is wrong
I believe the problem is two-fold:
1) First of all chrome incorrectly stores the httpVersion when the value is h2 as "unknown" in the generated har file
Here is how the request shows in Chrome's developer tools:
[Image: cbyixzbbb]

However when you export to a har chrome will save as "unknown"
$ grep httpVersion chrome+protocol.har |sort|uniq -c|sort
56 "httpVersion": "unknown",
104 "httpVersion": "HTTP/1.1",

I verified Firefox exports the httpVersion correctly as "HTTP/2.0"
$ grep httpVersion Downloads/firefox+protocol.har |sort|uniq -c|sort
2 "httpVersion": "",
64 "httpVersion": "HTTP/2.0",
74 "httpVersion": "HTTP/1.1",

2) The second issue, and what I think is relevant here is that the har generated by WPT contains the string "me:" (at least for me) as httpVersion disregarding if you selected Chrome or Firefox as the Browser for the test.

(03-04-2016 01:22 AM)shmilla Wrote:  If you export a HAR file from webpagetest for an HTTP2 site, there seems to be something weird with the response code. Or am I misinterpreting this?

Charles (RAW response view)
us: 200

Google HAR viewer shows response as:
200 OK us:

Opening the HAR as text or in jSON viewer I see
"HTTPVersion" : "US:" , shouldn't that be the HTTP version?

Just out of curiosity, how is the HAR supposed to show HTTP2? I exported a HAR from CHROME directly and it just shows:
"response": {
"status": 200,
"statusText": "OK",
"httpVersion": "unknown",i

Also, looking at another WPT Har export of an HTTP2 site, it looks like the HAR is missing the status text. Trivial since we have the code, but noticed the difference,so thought I'd mention it

Webpagetest HAR export of HTTP2 content:
"response": {
"status": 200,
"statusText": "",
"httpVersion": "us:",

CHROME HAR export of same page
"response": {
"status": 200,
"statusText": "OK",
"httpVersion": "unknown",
Find all posts by this user
Quote this message in a reply
Post Reply 

Messages In This Thread
RE: HAR file and HTTP2 - httpversion is wrong - jgarza - 03-04-2016 06:29 AM

Forum Jump:

User(s) browsing this thread: 1 Guest(s)