I'm trying download a video from YouTube by pytube but it throws this error below:
url_youtube age restricted, and can't be accessed without logging in.
Some posts says to open pytube -> innertube.py and change the line 223:
def __init__(self, client='ANDROID_MUSIC', use_oauth=False, allow_cache=True)
to:
def __init__(self, client='ANDROID', use_oauth=False, allow_cache=True)
I did it but throws another error:
HTTP Error 400: Bad Request.
What can I do?