JSONDecodeError occurred when uploading dataset.
Environment:
- tensorbay 1.4.0
- Ubuntu 20.04
- python 3.8.5
Error message:
Traceback (most recent call last):
File "upload_nuScenes.py", line 15, in <module>
gas.upload_dataset(dataset, jobs=8)
File "/home/newbie/.local/lib/python3.8/site-packages/tensorbay/client/gas.py", line 411, in upload_dataset
dataset_client._upload_segment( # pylint: disable=protected-access
File "/home/newbie/.local/lib/python3.8/site-packages/tensorbay/client/dataset.py", line 860, in _upload_segment
multithread_upload(
File "/home/newbie/.local/lib/python3.8/site-packages/tensorbay/client/requests.py", line 342, in multithread_upload
future.result()
File "/usr/lib/python3.8/concurrent/futures/_base.py", line 432, in result
return self.__get_result()
File "/usr/lib/python3.8/concurrent/futures/_base.py", line 388, in __get_result
raise self._exception
File "/usr/lib/python3.8/concurrent/futures/thread.py", line 57, in run
result = self.fn(*self.args, **self.kwargs)
File "/home/newbie/.local/lib/python3.8/site-packages/tensorbay/client/dataset.py", line 861, in <lambda>
lambda args: segment_client.upload_frame(*args),
File "/home/newbie/.local/lib/python3.8/site-packages/tensorbay/client/segment.py", line 530, in upload_frame
version_id, etag = self._post_multipart_formdata(
File "/home/newbie/.local/lib/python3.8/site-packages/tensorbay/client/segment.py", line 146, in _post_multipart_formdata
response_headers = self._client.do(
File "/home/newbie/.local/lib/python3.8/site-packages/tensorbay/client/requests.py", line 279, in do
return self.session.request(method=method, url=url, **kwargs)
File "/home/newbie/.local/lib/python3.8/site-packages/tensorbay/client/requests.py", line 163, in request
error_code = response.json()["code"]
File "/usr/lib/python3/dist-packages/requests/models.py", line 888, in json
return complexjson.loads(
File "/usr/lib/python3/dist-packages/simplejson/__init__.py", line 518, in loads
return _default_decoder.decode(s)
File "/usr/lib/python3/dist-packages/simplejson/decoder.py", line 370, in decode
obj, end = self.raw_decode(s)
File "/usr/lib/python3/dist-packages/simplejson/decoder.py", line 400, in raw_decode
return self.scan_once(s, idx=_w(s, idx).end())
simplejson.errors.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
The last part of the uploading log:
ERROR:tensorbay.client.requests:requests.exceptions.ConnectionError: HTTPSConnectionPool(host='content-store-prod-version.oss-cn-shanghai.aliyuncs.com', port=443): Max retries exceeded with url: / (Caused by ReadTimeoutError("HTTPSConnectionPool(host='content-store-prod-version.oss-cn-shanghai.aliyuncs.com', port=443): Read timed out. (read timeout=30)"))
===================================================================
########################## HTTP Request ###########################
"url": https://content-store-prod-version.oss-cn-shanghai.aliyuncs.com/
"method": POST
"headers": {
"User-Agent": "python-requests/2.22.0",
"Accept-Encoding": "gzip, deflate",
"Accept": "*/*",
"Connection": "keep-alive",
"Content-Type": "multipart/form-data; boundary=8db056e91aa54e239e3d76a1fe557060",
"Content-Length": "696198"
}
"body":
--8db056e91aa54e239e3d76a1fe557060
b'Content-Disposition: form-data; name="OSSAccessKeyId"\r\n\r\n'
b'LTAI4FjgXD3yFJUat4KADigE'
--8db056e91aa54e239e3d76a1fe557060
b'Content-Disposition: form-data; name="Signature"\r\n\r\n'
b'41+Z00FnVUFKWQZdloESGBwxIR8='
--8db056e91aa54e239e3d76a1fe557060
b'Content-Disposition: form-data; name="policy"\r\n\r\n'
b'eyJjb25kaXRpb25zIjpbWyJzdGFydHMtd2l0aCIsIiRrZXkiLCJiYTg4NzljMjUzZmM4Njg1MThkMDhhMjFmM2Y2Y2JmOS8wMTg2ZjUxZS00MDZkLTQzZWUtOWU0MC04MGE5ZDMwOGExNGEvLnNlZ21lbnQvdjEuMC10cmFpbnZhbC9zY2VuZS0wMDY0Ly5zZWdtZW50X2VuZC8iXV0sImV4cGlyYXRpb24iOiIyMDIxLTA1LTE4VDA4OjEwOjI3WiJ9'
--8db056e91aa54e239e3d76a1fe557060
b'Content-Disposition: form-data; name="success_action_status"\r\n\r\n'
b'200'
--8db056e91aa54e239e3d76a1fe557060
b'Content-Disposition: form-data; name="key"\r\n\r\n'
b'ba8879c253fc868518d08a21f3f6cbf9/0186f51e-406d-43ee-9e40-80a9d308a14a/.segment/v1.0-trainval/scene-0064/.segment_end/n008-2018-08-01-15-52-19-0400__LIDAR_TOP__1533153294197161.pcd.bin'
--8db056e91aa54e239e3d76a1fe557060
b'Content-Disposition: form-data; name="file"; filename="n008-2018-08-01-15-52-19-0400__LIDAR_TOP__1533153294197161.pcd.bin"\r\n\r\n'
[695040 bytes of object data]
--8db056e91aa54e239e3d76a1fe557060--