Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ModuleNotFoundError #39

Open
srijeetHalder opened this issue Apr 7, 2017 · 4 comments
Open

ModuleNotFoundError #39

srijeetHalder opened this issue Apr 7, 2017 · 4 comments

Comments

@srijeetHalder
Copy link

Traceback (most recent call last):
File "C:\subtitle-downloader.py", line 19, in
import requests,time,re,zipfile
ModuleNotFoundError: No module named 'requests'
Traceback (most recent call last):
File "C:\subtitle-downloader.py", line 19, in
import requests,time,re,zipfile
ModuleNotFoundError: No module named 'requests'
Traceback (most recent call last):
File "C:\subtitle-downloader.py", line 19, in
import requests,time,re,zipfile
ModuleNotFoundError: No module named 'requests'
Traceback (most recent call last):
File "C:\subtitle-downloader.py", line 19, in
import requests,time,re,zipfile
ModuleNotFoundError: No module named 'requests'
GOTO was unexpected at this time.

Above error comes when I am using the script.

@marauderlabs
Copy link
Contributor

same as #25. Already reported.

@manojmj92
Copy link
Owner

manojmj92 commented Apr 7, 2017 via email

@jay-ramani
Copy link

The latest version of the script is broken for packages and functionality as well.

Installed the requests, lxml, and BeautifulSoup packages. However, the script remains broken for SubDB search included! I manually searched on SubDB for many movies and found subtitles. Example, Moneyball released in 2011. The script however doesn't download from SubDB, I commented the SubScene code and put some debugs to find it's giving a 404 error.

When was this last tested to be working?

@ewwink
Copy link

ewwink commented Apr 29, 2017

there are few unnecessary module in this repos, like requests its only shorthand for urllib and not builtin module and we can replace with function get() like

def get(url):
     req = urllib2.Request(url)
     html = urllib2.urlopen(req).read()
     return html

second is module bs4 (BeautifulSoup) known as super slow html parser (http://blog.dispatched.ch/2010/08/16/beautifulsoup-vs-lxml-performance/) use instead lxml directly or powerful Regex so dont need to install module lxml.
another problem is search results is no longer with structure a > span tags but to capture the results we can use regex
re.compile('href="(/subtitles/[^"]+)"').findall(html)
I'm not an expert so let wait @manojmj92 to completely rewrite this project 😃

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants