Closed Xiinergy closed 2 years ago
I have the exact same problem right now
same
Go to last error path in ur console site-packages\pytube\cipher.py line Number 30 or 33
from var_regex = re.compile(r"^\w+\W")
change to var_regex = re.compile(r"^\$*\w+\W")
hope That Solves Issue
what console are we talking about here? The file name console.py or?
it worked 👍
Great !!
@MDAmirPathan Thanks
Go to last error path in ur console site-packages\pytube\cipher.py line Number 30 or 33 from
var_regex = re.compile(r"^\w+\W")
change tovar_regex = re.compile(r"^\$*\w+\W")
hope That Solves Issue
where does one find this?
You need to find the cypher.py file.
You can find it by finding the lib folder, and then site-packages, then pytube, and in that folder there should be a file called cipher.py
lib\site-packages\pytube\cipher.py"
Or if you are using a python editer like pycharm, you can search for cipher.py, in the right top corner, there should be a search-loop
do u happen to know where these folders are on Mac
I unfortunately dont use Mac, sorry
Go to last error path in ur console site-packages\pytube\cipher.py line Number 30 or 33 from
var_regex = re.compile(r"^\w+\W")
change tovar_regex = re.compile(r"^\$*\w+\W")
hope That Solves Issue
Found it and edited it but im still getting the issue
This started happening after I downloaded the new version, it gives me this error when it starts downloading the background videos.
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "C:\Users\Aigars\Desktop\RedditVideoMakerBot-master patched\RedditVideoMakerBot-master\main.py", line 39, in
main()
File "C:\Users\Aigars\Desktop\RedditVideoMakerBot-master patched\RedditVideoMakerBot-master\main.py", line 32, in main
download_background()
File "C:\Users\Aigars\Desktop\RedditVideoMakerBot-master patched\RedditVideoMakerBot-master\video_creation\background.py", line 39, in download_background
YouTube(uri).streams.filter(res="720p").first().download("assets/backgrounds",
File "C:\Users\Aigars\AppData\Local\Programs\Python\Python310\lib\site-packages\pytube__main.py", line 296, in streams
return StreamQuery(self.fmt_streams)
File "C:\Users\Aigars\AppData\Local\Programs\Python\Python310\lib\site-packages\pytube__main__.py", line 188, in fmt_streams
extract.apply_signature(stream_manifest, self.vid_info, self.js)
File "C:\Users\Aigars\AppData\Local\Programs\Python\Python310\lib\site-packages\pytube\extract.py", line 409, in apply_signature
cipher = Cipher(js=js)
File "C:\Users\Aigars\AppData\Local\Programs\Python\Python310\lib\site-packages\pytube\cipher.py", line 33, in init
raise RegexMatchError(
pytube.exceptions.RegexMatchError: init__: could not find match for ^\w+\W