Open somanyadav opened 2 years ago
me too
>>> yt = pytube.YouTube('https://www.youtube.com/watch?v=8fNirFEh1i0')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "D:\trading\venvpytube\lib\site-packages\pytube\__main__.py", line 91, in __init__
self.prefetch()
File "D:\trading\venvpytube\lib\site-packages\pytube\__main__.py", line 181, in prefetch
self.vid_info_raw = request.get(self.vid_info_url)
File "D:\trading\venvpytube\lib\site-packages\pytube\request.py", line 36, in get
return _execute_request(url).read().decode("utf-8")
File "D:\trading\venvpytube\lib\site-packages\pytube\request.py", line 24, in _execute_request
return urlopen(request) # nosec
File "C:\Program Files\Python310\lib\urllib\request.py", line 216, in urlopen
return opener.open(url, data, timeout)
File "C:\Program Files\Python310\lib\urllib\request.py", line 525, in open
response = meth(req, response)
File "C:\Program Files\Python310\lib\urllib\request.py", line 634, in http_response
response = self.parent.error(
File "C:\Program Files\Python310\lib\urllib\request.py", line 557, in error
result = self._call_chain(*args)
File "C:\Program Files\Python310\lib\urllib\request.py", line 496, in _call_chain
result = func(*args)
File "C:\Program Files\Python310\lib\urllib\request.py", line 749, in http_error_302
return self.parent.open(new, timeout=req.timeout)
File "C:\Program Files\Python310\lib\urllib\request.py", line 525, in open
response = meth(req, response)
File "C:\Program Files\Python310\lib\urllib\request.py", line 634, in http_response
response = self.parent.error(
File "C:\Program Files\Python310\lib\urllib\request.py", line 563, in error
return self._call_chain(*args)
File "C:\Program Files\Python310\lib\urllib\request.py", line 496, in _call_chain
result = func(*args)
File "C:\Program Files\Python310\lib\urllib\request.py", line 643, in http_error_default
raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 410: Gone
>>>
this project is dead
got same(
same
@swiftyy-mage
this project is dead looks like last commit and package release was over two years ago
there is an issue for the same (or very similar) thing on the original pytube pytube repo
i uninstalled pytube3 and installed pytube with --upgrade (as i think i saw mentioned somewhere, but i'm not sure it's necessary)
python -m pip uninstall pytube3
python -m pip install pytube --upgrade
then downloading one of the streams by itag worked fine
(although the webm has no audio, last time i used pytube, webms downloaded with audio and video... oh well, i guess i'll figure that out too)
the video only webm is dash versus progressive
i thought this might be the cause
downloading dash streams requires download separate streaams, one audio and one video, then post-processing with ffmpeg or something similar
so if there are progressive streams available for your video, that's obviously the most convenient to download
cheers!
yeah guys, use the original pytube repo, it has a bigger community and more help https://github.com/pytube/pytube
On running, import pytube from pytube import YouTube yt = YouTube('https://www.youtube.com/watch?v=fJmZwtgToxM')
I'm getting,
_HTTPError Traceback (most recent call last) in ()
1 from pytube import YouTube
----> 2 yt = YouTube('https://www.youtube.com/watch?v=fJmZwtgToxM')
14 frames /usr/lib/python3.7/urllib/request.py in http_error_default(self, req, fp, code, msg, hdrs) 647 class HTTPDefaultErrorHandler(BaseHandler): 648 def http_error_default(self, req, fp, code, msg, hdrs): --> 649 raise HTTPError(req.full_url, code, msg, hdrs, fp) 650 651 class HTTPRedirectHandler(BaseHandler):
HTTPError: HTTP Error 410: Gone_