mirror of
				https://github.com/kovidgoyal/calibre.git
				synced 2025-11-04 03:27:00 -05:00 
			
		
		
		
	pep8
This commit is contained in:
		
							parent
							
								
									2aa41c859b
								
							
						
					
					
						commit
						148df09652
					
				@ -3,9 +3,9 @@ __copyright__ = '2011, Pat Stapleton <pat.stapleton at gmail.com>'
 | 
				
			|||||||
'''
 | 
					'''
 | 
				
			||||||
https://www.spectator.com.au/
 | 
					https://www.spectator.com.au/
 | 
				
			||||||
'''
 | 
					'''
 | 
				
			||||||
import re
 | 
					 | 
				
			||||||
from calibre.web.feeds.recipes import BasicNewsRecipe
 | 
					from calibre.web.feeds.recipes import BasicNewsRecipe
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
class SpectatorAU(BasicNewsRecipe):
 | 
					class SpectatorAU(BasicNewsRecipe):
 | 
				
			||||||
    title = 'Spectator Australia'
 | 
					    title = 'Spectator Australia'
 | 
				
			||||||
    __author__ = 'Pat Stapleton, Dean Cording, James Cridland'
 | 
					    __author__ = 'Pat Stapleton, Dean Cording, James Cridland'
 | 
				
			||||||
@ -24,11 +24,26 @@ class SpectatorAU(BasicNewsRecipe):
 | 
				
			|||||||
    publication_type = 'newspaper'
 | 
					    publication_type = 'newspaper'
 | 
				
			||||||
    extra_css = '.article-header__author{margin-bottom:20px;}'
 | 
					    extra_css = '.article-header__author{margin-bottom:20px;}'
 | 
				
			||||||
    conversion_options = {
 | 
					    conversion_options = {
 | 
				
			||||||
        'comments': description, 'tags': category, 'language': language, 'publisher': publisher, 'linearize_tables': False
 | 
					        'comments': description,
 | 
				
			||||||
 | 
					        'tags': category,
 | 
				
			||||||
 | 
					        'language': language,
 | 
				
			||||||
 | 
					        'publisher': publisher,
 | 
				
			||||||
 | 
					        'linearize_tables': False
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    keep_only_tags = [dict(attrs={'class': ['article']})]
 | 
					    keep_only_tags = [dict(attrs={'class': ['article']})]
 | 
				
			||||||
    remove_tags = [dict(attrs={'class': ['big-author','article-header__category','margin-menu','related-stories','disqus_thread','middle-promo','show-comments','article-tags']}), dict(name=['h4','hr'])]
 | 
					    remove_tags = [
 | 
				
			||||||
 | 
					        dict(
 | 
				
			||||||
 | 
					            attrs={
 | 
				
			||||||
 | 
					                'class': [
 | 
				
			||||||
 | 
					                    'big-author', 'article-header__category', 'margin-menu',
 | 
				
			||||||
 | 
					                    'related-stories', 'disqus_thread', 'middle-promo',
 | 
				
			||||||
 | 
					                    'show-comments', 'article-tags'
 | 
				
			||||||
 | 
					                ]
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					        ),
 | 
				
			||||||
 | 
					        dict(name=['h4', 'hr'])
 | 
				
			||||||
 | 
					    ]
 | 
				
			||||||
    remove_attributes = ['width', 'height']
 | 
					    remove_attributes = ['width', 'height']
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    feeds = [
 | 
					    feeds = [
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user