From ba1cc73617be835dd483a712d6966bd4cd2a35bb Mon Sep 17 00:00:00 2001 From: Shixin Date: Tue, 8 Sep 2020 12:24:54 +0800 Subject: [PATCH] Update http.py --- googleapiclient/http.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/googleapiclient/http.py b/googleapiclient/http.py index d9c3d2ae19a..837a355e0d6 100644 --- a/googleapiclient/http.py +++ b/googleapiclient/http.py @@ -1903,7 +1903,7 @@ def build_http(): http_timeout = socket.getdefaulttimeout() else: http_timeout = DEFAULT_HTTP_TIMEOUT_SEC - http = httplib2.Http(timeout=http_timeout) + http = set_user_agent(httplib2.Http(timeout=http_timeout), '-kfpipeline-') # 308's are used by several Google APIs (Drive, YouTube) # for Resumable Uploads rather than Permanent Redirects. # This asks httplib2 to exclude 308s from the status codes