This commit is contained in:
Kovid Goyal 2012-11-08 13:38:48 +05:30
parent 4f23afc3ae
commit 85a427af83
2 changed files with 13 additions and 17 deletions

View File

@ -30,11 +30,6 @@ class tvn24(BasicNewsRecipe):
feeds = [(u'Najnowsze', u'http://www.tvn24.pl/najnowsze.xml'), ]
#(u'Polska', u'www.tvn24.pl/polska.xml'), (u'\u015awiat', u'http://www.tvn24.pl/swiat.xml'), (u'Sport', u'http://www.tvn24.pl/sport.xml'), (u'Biznes', u'http://www.tvn24.pl/biznes.xml'), (u'Meteo', u'http://www.tvn24.pl/meteo.xml'), (u'Micha\u0142ki', u'http://www.tvn24.pl/michalki.xml'), (u'Kultura', u'http://www.tvn24.pl/kultura.xml')]
def preprocess_html(self, soup):
for item in soup.findAll(style=True):
del item['style']
return soup
def preprocess_html(self, soup):
for alink in soup.findAll('a'):
if alink.string is not None:

View File

@ -14,6 +14,7 @@ device. This class handles device detection.
import os, subprocess, time, re, sys, glob
from itertools import repeat
from calibre import prints, as_unicode
from calibre.devices.interface import DevicePlugin
from calibre.devices.errors import DeviceError
from calibre.devices.usbms.deviceconfig import DeviceConfig
@ -903,7 +904,7 @@ class Device(DeviceConfig, DevicePlugin):
winutil.eject_drive(bytes(d)[0])
except Exception as e:
try:
prints(as_unicode(e))
prints("Eject failed:", as_unicode(e))
except:
pass