Skip to content

Commit

Permalink
converted string 'xmlcharrefreplace' to 'utf-8' encoding
Browse files Browse the repository at this point in the history
  • Loading branch information
iamsudip committed Oct 18, 2013
1 parent c4d936c commit 471e541
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions pysub-dl
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
#!/usr/bin/env python

__appname__ = "pysub-dl"
__version__ = "0.2.7"
__version__ = "0.2.8"
__author__ = "iamsudip <[email protected]>"
__license__ = "MIT"

import argparse
import sys
from HTMLParser import HTMLParser
import requests
from BeautifulSoup import BeautifulSoup
from download_it import download_file
Expand Down Expand Up @@ -54,10 +55,11 @@ def alternate_search():
response = requests.get(url)
soup = BeautifulSoup(response.text)
del response
parser = HTMLParser()
counter = 1
for popular in soup.findAll('div', attrs={'class' : 'title'}):
for link in popular.findAll('a'):
movie_list[link.text] = 'http://subscene.com' + link.get('href') + '/' + args.language
movie_list[parser.unescape(link.text)] = 'http://subscene.com' + link.get('href') + '/' + args.language
for key in movie_list.keys():
print str(counter) + ". " + key
temp[counter] = key
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
requirements.append('requests')

setup(name = 'pysub-dl',
version = '0.2.7',
version = '0.2.8',
description = "Script to download movie subtitles automatically",
long_description = long_description,
platforms = ["Linux"],
Expand Down

0 comments on commit 471e541

Please sign in to comment.