Skip to content
This repository was archived by the owner on Jul 22, 2021. It is now read-only.
This repository was archived by the owner on Jul 22, 2021. It is now read-only.

OverflowError: Python int too large to convert to C long #220

@armqtt

Description

@armqtt

Bug Report.

When I use pydrive to download video that bigger than around 5GB. The API show this message. How to solve this.

By the way, my python version is Python 3.8.2 with windows platform.

Downloading file: video.mp4 5.0GiB .\movie

Traceback (most recent call last):
File "H:\PyGdriveAPI\gdriveDownload.py", line 196, in
> doDownload(diffResult)
File "H:\PyGdriveAPI\gdriveDownload.py", line 166, in doDownload
doDownload(sub, path + '\' + sub['foldername'])
File "H:\PyGdriveAPI\gdriveDownload.py", line 160, in doDownload
> downloadFile.GetContentFile(downFileName + ts)
File "C:\Users\su\AppData\Local\Programs\Python\Python39\lib\site-packages\pydrive\files.py", line 210, in GetContentFile
self.FetchContent(mimetype, remove_bom)
File "C:\Users\su\AppData\Local\Programs\Python\Python39\lib\site-packages\pydrive\files.py", line 43, in _decorated
> return decoratee(self, *args, **kwargs)
File "C:\Users\su\AppData\Local\Programs\Python\Python39\lib\site-packages\pydrive\files.py", line 255, in FetchContent
self.content = io.BytesIO(self._DownloadFromUrl(download_url))
File "C:\Users\su\AppData\Local\Programs\Python\Python39\lib\site-packages\pydrive\auth.py", line 75, in _decorated
> return decoratee(self, *args, **kwargs)
File "C:\Users\su\AppData\Local\Programs\Python\Python39\lib\site-packages\pydrive\files.py", line 503, in DownloadFromUrl
resp, content = self.http.request(url)
File "C:\Users\su\AppData\Local\Programs\Python\Python39\lib\site-packages\oauth2client\transport.py", line 173, in new_request
> resp, content = request(orig_request_method, uri, method, body,
File "C:\Users\su\AppData\Local\Programs\Python\Python39\lib\site-packages\oauth2client\transport.py", line 280, in request
return http_callable(uri, method=method, body=body, headers=headers,
File "C:\Users\su\AppData\Local\Programs\Python\Python39\lib\site-packages\httplib2_init
.py", line 1967, in request
> (response, content) = self.request(
File "C:\Users\su\AppData\Local\Programs\Python\Python39\lib\site-packages\httplib2_init
.py", line 1639, in _request
(response, content) = self.conn_request(
File "C:\Users\su\AppData\Local\Programs\Python\Python39\lib\site-packages\httplib2_init
.py", line 1607, in _conn_request
> content = response.read()
File "C:\Users\su\AppData\Local\Programs\Python\Python39\lib\http\client.py", line 471, in read
s = self._safe_read(self.length)
File "C:\Users\su\AppData\Local\Programs\Python\Python39\lib\http\client.py", line 612, in _safe_read
> data = self.fp.read(amt)
File "C:\Users\su\AppData\Local\Programs\Python\Python39\lib\socket.py", line 704, in readinto
return self._sock.recv_into(b)
File "C:\Users\su\AppData\Local\Programs\Python\Python39\lib\ssl.py", line 1241, in recv_into
> return self.read(nbytes, buffer)
File "C:\Users\su\AppData\Local\Programs\Python\Python39\lib\ssl.py", line 1099, in read
return self._sslobj.read(len, buffer)
OverflowError: Python int too large to convert to C long

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions