BingAds / BingAds-Python-SDK

Other
117 stars 162 forks source link

[Errno 104] Connection reset by peer #152

Closed karthick-jaganathan closed 4 years ago

karthick-jaganathan commented 4 years ago

We are currently seeing the following error when we try and request all AdExtensionsAssociations

Method: GetAdExtensionsAssociations AdExtensionType: 'LocationAdExtension' AssociationType: 'Campaign'

Traceback (most recent call last):
  File "/cv/vendor/lib/python2.7/site-packages/bingads-12.13.3.2-py2.7.egg/bingads/service_client.py", line 266, in __call__
    response = self.service_client.soap_client.service.__getattr__(self.name)(*args, **kwargs)
  File "/cv/vendor/lib/python2.7/site-packages/suds_jurko-0.6-py2.7.egg/suds/client.py", line 521, in __call__
    return client.invoke(args, kwargs)
  File "/cv/vendor/lib/python2.7/site-packages/suds_jurko-0.6-py2.7.egg/suds/client.py", line 581, in invoke
    result = self.send(soapenv)
  File "/cv/vendor/lib/python2.7/site-packages/suds_jurko-0.6-py2.7.egg/suds/client.py", line 613, in send
    reply = self.options.transport.send(request)
  File "/cv/vendor/lib/python2.7/site-packages/suds_jurko-0.6-py2.7.egg/suds/transport/https.py", line 66, in send
    return HttpTransport.send(self, request)
  File "/cv/vendor/lib/python2.7/site-packages/googleads-14.1.0-py2.7.egg/googleads/util.py", line 127, in PatchedHttpTransportSend
    fp = self.u2open(u2request)
  File "/cv/vendor/lib/python2.7/site-packages/suds_jurko-0.6-py2.7.egg/suds/transport/http.py", line 132, in u2open
    return url.open(u2request, timeout=tm)
  File "/cv/vendor/lib/python2.7/urllib2.py", line 431, in open
    response = self._open(req, data)
  File "/cv/vendor/lib/python2.7/urllib2.py", line 449, in _open
    '_open', req)
  File "/cv/vendor/lib/python2.7/urllib2.py", line 409, in _call_chain
    result = func(*args)
  File "/cv/vendor/lib/python2.7/urllib2.py", line 1240, in https_open
    context=self._context)
  File "/cv/vendor/lib/python2.7/urllib2.py", line 1200, in do_open
    r = h.getresponse(buffering=True)
  File "/cv/vendor/lib/python2.7/httplib.py", line 1073, in getresponse
    response.begin()
  File "/cv/vendor/lib/python2.7/httplib.py", line 415, in begin
    version, status, reason = self._read_status()
  File "/cv/vendor/lib/python2.7/httplib.py", line 371, in _read_status
    line = self.fp.readline(_MAXLINE + 1)
  File "/cv/vendor/lib/python2.7/socket.py", line 476, in readline
    data = self._sock.recv(self._rbufsize)
  File "/cv/vendor/lib/python2.7/ssl.py", line 714, in recv
    return self.read(buflen)
  File "/cv/vendor/lib/python2.7/ssl.py", line 608, in read
    v = self._sslobj.read(len or 1024)
error: [Errno 104] Connection reset by peer
 <ns2:Body>
      <ns1:GetAdExtensionsAssociationsRequest>
         <ns1:AccountId>value</ns1:AccountId>
         <ns1:AdExtensionType>LocationAdExtension</ns1:AdExtensionType>
         <ns1:AssociationType>Campaign</ns1:AssociationType>
         <ns1:EntityIds>
            <ns0:long>value</ns0:long>
            <ns0:long>value</ns0:long>
            <ns0:long>value</ns0:long>
         </ns1:EntityIds>
      </ns1:GetAdExtensionsAssociationsRequest>
   </ns2:Body>

Script is not failing, if requested with single entity id

<ns2:Body>
      <ns1:GetAdExtensionsAssociationsRequest>
         <ns1:AccountId>value</ns1:AccountId>
         <ns1:AdExtensionType>LocationAdExtension</ns1:AdExtensionType>
         <ns1:AssociationType>Campaign</ns1:AssociationType>
         <ns1:EntityIds>
            <ns0:long>value</ns0:long>
         </ns1:EntityIds>
      </ns1:GetAdExtensionsAssociationsRequest>
   </ns2:Body>

Am I missing something here or is this a bug?

qitia commented 4 years ago

@Karthick145 Do you still face this issue? Do you have a trackingid/request id for the failed call?

qitia commented 4 years ago

close as of now @Karthick145 as not hear anything anymore. Please reopen it with more detail if you still see this issue.