Hi,

I'm trying to figure out how to configure proxy for Python client 6.1.0, 
for which the API version I believe is v201708. I passed in proxy info like 
the following when creating the service client.

        http_proxy=googleads.common.ProxyConfig.Proxy('proxy host w/o 
http://', 8080)

        https_proxy=googleads.common.ProxyConfig.Proxy('proxy host w/o 
https://', 8080)

        proxy_config = googleads.common.ProxyConfig(http_proxy=http_proxy, 
https_proxy=https_proxy)

        client = adwords.AdWordsClient(DEVELOPER_TOKEN, OAUTH_CLIENT, 
USER_AGENT, client_customer_id=account_id, proxy_config=proxy_config)

However, when accessing the API it looks like oauth2 client still tries to 
access google servers like dfw25s27-in-f13.1e100.net.https directly. Below 
is the stack trace concerning the Python client.

  File "/usr/local/lib/python2.7/site-packages/googleads/common.py", line 
743, in MakeSoapRequest

    self._header_handler.SetHeaders(self.suds_client)

  File "/usr/local/lib/python2.7/site-packages/googleads/adwords.py", line 
554, in SetHeaders

    http_headers = self._adwords_client.oauth2_client.CreateHttpHeader()

  File "/usr/local/lib/python2.7/site-packages/googleads/oauth2.py", line 
211, in CreateHttpHeader

    self.Refresh()

  File "/usr/local/lib/python2.7/site-packages/googleads/oauth2.py", line 
226, in Refresh

    self.proxy_config.disable_certificate_validation)))

  File "/usr/local/lib/python2.7/site-packages/oauth2client/client.py", 
line 545, in refresh

    self._refresh(http)

  File "/usr/local/lib/python2.7/site-packages/oauth2client/client.py", 
line 749, in _refresh

    self._do_refresh_request(http)

  File "/usr/local/lib/python2.7/site-packages/oauth2client/client.py", 
line 780, in _do_refresh_request

    body=body, headers=headers)

  File "/usr/local/lib/python2.7/site-packages/oauth2client/transport.py", 
line 282, in request

    connection_type=connection_type)

  File "/usr/local/lib/python2.7/site-packages/httplib2/__init__.py", line 
1659, in request

    (response, content) = self._request(conn, authority, uri, request_uri, 
method, body, headers, redirections, cachekey)

  File "/usr/local/lib/python2.7/site-packages/httplib2/__init__.py", line 
1399, in _request

    (response, content) = self._conn_request(conn, request_uri, method, 
body, headers)

  File "/usr/local/lib/python2.7/site-packages/httplib2/__init__.py", line 
1355, in _conn_request

    response = conn.getresponse()

  File "/usr/local/lib/python2.7/httplib.py", line 1123, in getresponse

    raise ResponseNotReady()

httplib.ResponseNotReady

Any idea whether this can be fixed on our side or is a bug with the Python 
client?

Thanks,
Sha Liu


-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and Google+:
https://googleadsdeveloper.blogspot.com/
https://plus.google.com/+GoogleAdsDevelopers/posts
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/2e1750ea-39ee-4a2a-ab66-ed6034153408%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to