youtube-upload icon indicating copy to clipboard operation
youtube-upload copied to clipboard

oauth.json is deleted after upload

Open Esokrates opened this issue 3 years ago • 4 comments

Problem

My directory looks like this:

client_secrets.json  oauth.json test.mp4  test.py

and test.py like this:

from youtube_upload.client import YoutubeUploader

uploader = YoutubeUploader()
uploader.authenticate()

# Video options
options = {
    "title" : "Example title", # The video title
    "description" : "Example description", # The video description
    "categoryId" : "22",
    "privacyStatus" : "private", # Video privacy. Can either be "public", "private", or "unlisted"
    "kids" : False, # Specifies if the Video if for kids or not. Defaults to False.
}

# upload video
uploader.upload("./test.mp4", options)
uploader.close()

After running test.py the oauth.json file is deleted for some reason, but I would like too keep it in order not to have authenticate everytime I use the script.

Esokrates avatar Jan 29 '22 11:01 Esokrates