Browse Source

add extra info to headers.json

Nick Sweeting 1 year ago
parent
commit
38ca5c3228
1 changed files with 4 additions and 0 deletions
  1. 4 0
      archivebox/util.py

+ 4 - 0
archivebox/util.py

@@ -271,7 +271,11 @@ def get_headers(url: str, timeout: int=None) -> str:
     
     
     return pyjson.dumps(
     return pyjson.dumps(
         {
         {
+            'URL': url,
             'Status-Code': response.status_code,
             'Status-Code': response.status_code,
+            'Elapsed': response.elapsed,
+            'Encoding': response.encoding,
+            'Apparent-Encoding': response.apparent_encoding,
             **dict(response.headers),
             **dict(response.headers),
         },
         },
         indent=4,
         indent=4,