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

How to see the progress of files which is getting uploaded #1404

Open
Eldho1416 opened this issue May 3, 2024 · 0 comments
Open

How to see the progress of files which is getting uploaded #1404

Eldho1416 opened this issue May 3, 2024 · 0 comments
Assignees

Comments

@Eldho1416
Copy link

Eldho1416 commented May 3, 2024

I'm have been uploading a zipped file to drive using python and I'm not able to figure out how to see the progress of file which is getting uploaded. Is there anyway to see the progress bar, i'm attaching the part of code where i'm uploading the file.

Thanks

# Call the Drive v3 API
file_metadata = {
"name": os.path.basename(zipped_file),
"mimeType": "application/x-zip-compressed",
"parents": [self.folder_id]
}
media = MediaFileUpload(zipped_file, mimetype="application/zip", resumable=True)

file = (
service.files()
.create(body=file_metadata, media_body=media, fields="id")
.execute()
)
logger.info(f'File with ID: "{file.get("id")}" has been uploaded.')
  • Python version: Python 3.12.2
  • OS: Windows
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

2 participants