mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
pep8
This commit is contained in:
parent
f8a298cef9
commit
f207feb95f
@ -11,7 +11,6 @@
|
|||||||
##
|
##
|
||||||
__license__ = 'GPL v3'
|
__license__ = 'GPL v3'
|
||||||
__author__ = '2013, Carlos Alves <carlosalves90@gmail.com>'
|
__author__ = '2013, Carlos Alves <carlosalves90@gmail.com>'
|
||||||
|
|
||||||
'''
|
'''
|
||||||
diarioelpueblo.com.uy
|
diarioelpueblo.com.uy
|
||||||
'''
|
'''
|
||||||
@ -37,11 +36,18 @@ class General(BasicNewsRecipe):
|
|||||||
keep_only_tags = [dict(name='div', attrs={'class': 'post-alt blog'})]
|
keep_only_tags = [dict(name='div', attrs={'class': 'post-alt blog'})]
|
||||||
|
|
||||||
remove_tags = [
|
remove_tags = [
|
||||||
|
dict(
|
||||||
|
name='div',
|
||||||
|
attrs={
|
||||||
|
'class': ['hr', 'titlebar', 'volver-arriba-right', 'navigation']
|
||||||
|
}
|
||||||
|
),
|
||||||
dict(name='div', attrs={
|
dict(name='div', attrs={
|
||||||
'class': ['hr', 'titlebar', 'volver-arriba-right', 'navigation']}),
|
'id': 'comment suckerfish crp_related'.split(),
|
||||||
dict(name='div', attrs={'id': 'comment',
|
}),
|
||||||
'id': 'suckerfish', 'id': 'crp_related'}),
|
dict(name='h3', attrs={
|
||||||
dict(name='h3', attrs={'class': ['post_date']}),
|
'class': ['post_date']
|
||||||
|
}),
|
||||||
dict(name=['object', 'link'])
|
dict(name=['object', 'link'])
|
||||||
]
|
]
|
||||||
|
|
||||||
@ -54,9 +60,7 @@ class General(BasicNewsRecipe):
|
|||||||
img{margin-bottom: 0.4em; display:block;}
|
img{margin-bottom: 0.4em; display:block;}
|
||||||
'''
|
'''
|
||||||
|
|
||||||
feeds = [
|
feeds = [(u'Articulos', u'http://www.diarioelpueblo.com.uy/feed')]
|
||||||
(u'Articulos', u'http://www.diarioelpueblo.com.uy/feed')
|
|
||||||
]
|
|
||||||
|
|
||||||
def get_cover_url(self):
|
def get_cover_url(self):
|
||||||
return None
|
return None
|
||||||
|
@ -66,7 +66,7 @@ class General(BasicNewsRecipe):
|
|||||||
index = 'https://www.elpais.com.uy/impresa/'
|
index = 'https://www.elpais.com.uy/impresa/'
|
||||||
soup = self.index_to_soup(index)
|
soup = self.index_to_soup(index)
|
||||||
link_item = soup.find('a', attrs={'class': 'page-link link-module'})
|
link_item = soup.find('a', attrs={'class': 'page-link link-module'})
|
||||||
#print link_item
|
# print link_item
|
||||||
if link_item:
|
if link_item:
|
||||||
cover_url = 'https://www.elpais.com.uy' + link_item.get('href')
|
cover_url = 'https://www.elpais.com.uy' + link_item.get('href')
|
||||||
return cover_url
|
return cover_url
|
||||||
|
@ -96,6 +96,7 @@ class TrimImage(QDialog):
|
|||||||
if self.canvas.trim_image():
|
if self.canvas.trim_image():
|
||||||
self.accept()
|
self.accept()
|
||||||
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
app = QApplication([])
|
app = QApplication([])
|
||||||
fname = sys.argv[-1]
|
fname = sys.argv[-1]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user