Question

I don't know nothing about python and I'm trying to upload a video to youtube.

I already got the code and I just need to say which file I want to upload in this line:

argparser.add_argument("--file", required=True, help="Video file to upload")

Yet I don't know where to place my video name. For example: "video.mp4". I tried default="video.mp4", "video.mp4" after "--file", but I get this error:

argument --file is required
Was it helpful?

Solution

It's a command line argument parser. So you add it as an argument while calling the python file.

like:

python uploadexample.py --file video.mp4
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top