Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Timeout errors with the CLI #162

Open
amelio-vazquez-reina opened this issue Jun 28, 2016 · 0 comments
Open

Timeout errors with the CLI #162

amelio-vazquez-reina opened this issue Jun 28, 2016 · 0 comments

Comments

@amelio-vazquez-reina
Copy link

amelio-vazquez-reina commented Jun 28, 2016

I am running into timeout errors when downloading data: (the resulting my_data.csv file is also empty). Why is it failing?

> qds.py --token=$QUBOLE_KEY_AVAZQUEZ hivecmd getresult 28091451 > my_data.csv

Traceback (most recent call last):
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 385, in _make_request
    httplib_response = conn.getresponse(buffering=True)
TypeError: getresponse() got an unexpected keyword argument 'buffering'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 387, in _make_request
    httplib_response = conn.getresponse()
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/http/client.py", line 1174, in getresponse
    response.begin()
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/http/client.py", line 282, in begin
    version, status, reason = self._read_status()
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/http/client.py", line 243, in _read_status
    line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1")
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/socket.py", line 575, in readinto
    return self._sock.recv_into(b)
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/ssl.py", line 924, in recv_into
    return self.read(nbytes, buffer)
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/ssl.py", line 786, in read
    return self._sslobj.read(len, buffer)
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/ssl.py", line 570, in read
    v = self._sslobj.read(len, buffer)
socket.timeout: The read operation timed out

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/requests/adapters.py", line 403, in send
    timeout=timeout
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 623, in urlopen
    _stacktrace=sys.exc_info()[2])
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/requests/packages/urllib3/util/retry.py", line 255, in increment
    raise six.reraise(type(error), error, _stacktrace)
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/requests/packages/urllib3/packages/six.py", line 310, in reraise
    raise value
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 578, in urlopen
    chunked=chunked)
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 389, in _make_request
    self._raise_timeout(err=e, url=url, timeout_value=read_timeout)
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 314, in _raise_timeout
    raise ReadTimeoutError(self, url, "Read timed out. (read timeout=%s)" % timeout_value)
requests.packages.urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='api.qubole.com', port=443): Read timed out. (read timeout=300)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/amelio/anaconda/envs/py35/bin/qds.py", line 603, in <module>
    sys.exit(main())
  File "/Users/amelio/anaconda/envs/py35/bin/qds.py", line 556, in main
    return cmdmain(a0, args)
  File "/Users/amelio/anaconda/envs/py35/bin/qds.py", line 194, in cmdmain
    return globals()[action + "action"](cmdclass, args)
  File "/Users/amelio/anaconda/envs/py35/bin/qds.py", line 160, in getresultaction
    return _getresult(cmdclass, cmd)
  File "/Users/amelio/anaconda/envs/py35/bin/qds.py", line 118, in _getresult
    cmd.get_results(sys.stdout, delim='\t')
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/qds_sdk/commands.py", line 177, in get_results
    r = conn.get(result_path, {'inline': inline})
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/qds_sdk/retry.py", line 22, in f_retry
    return f(*args, **kwargs)
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/qds_sdk/connection.py", line 52, in get
    return self._api_call("GET", path, params=params)
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/qds_sdk/connection.py", line 97, in _api_call
    return self._api_call_raw(req_type, path, data=data, params=params).json()
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/qds_sdk/connection.py", line 83, in _api_call_raw
    r = x.get(url, timeout=300, **kwargs)
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/requests/sessions.py", line 487, in get
    return self.request('GET', url, **kwargs)
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/requests/sessions.py", line 475, in request
    resp = self.send(prep, **send_kwargs)
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/requests/sessions.py", line 585, in send
    r = adapter.send(request, **kwargs)
  File "/Users/amelio/anaconda/envs/py35/lib/python3.5/site-packages/requests/adapters.py", line 479, in send
    raise ReadTimeout(e, request=request)
requests.exceptions.ReadTimeout: HTTPSConnectionPool(host='api.qubole.com', port=443): Read timed out. (read timeout=300)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant