mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Merge branch 'make-check-strict-happy' of https://github.com/un-pogaz/calibre
This commit is contained in:
commit
90a97caa3b
@ -143,7 +143,7 @@ class WSJ(BasicNewsRecipe):
|
|||||||
br.addheaders += [
|
br.addheaders += [
|
||||||
('Accept-Encoding', 'gzip'),
|
('Accept-Encoding', 'gzip'),
|
||||||
('cache-control', 'no-cache'),
|
('cache-control', 'no-cache'),
|
||||||
('x-api-key', ('e''b''2''4''0''8''c''d''2''7''f''8''9''1''3''d''4''2''1''f''a''3''d''5''c''3''d''0''7''c''c''f''0''3''4''c''b''4''4''8')),
|
('x-api-key', ('e''b''2''4''0''8''c''d''2''7''f''8''9''1''3''d''4''2''1''f''a''3''d''5''c''3''d''0''7''c''c''f''0''3''4''c''b''4''4''8')), # noqa: ISC001
|
||||||
]
|
]
|
||||||
return br
|
return br
|
||||||
|
|
||||||
|
@ -118,7 +118,7 @@ class WSJ(BasicNewsRecipe):
|
|||||||
br.addheaders += [
|
br.addheaders += [
|
||||||
('Accept-Encoding', 'gzip'),
|
('Accept-Encoding', 'gzip'),
|
||||||
('cache-control', 'no-cache'),
|
('cache-control', 'no-cache'),
|
||||||
('x-api-key', ('e''b''2''4''0''8''c''d''2''7''f''8''9''1''3''d''4''2''1''f''a''3''d''5''c''3''d''0''7''c''c''f''0''3''4''c''b''4''4''8')),
|
('x-api-key', ('e''b''2''4''0''8''c''d''2''7''f''8''9''1''3''d''4''2''1''f''a''3''d''5''c''3''d''0''7''c''c''f''0''3''4''c''b''4''4''8')), # noqa: ISC001
|
||||||
]
|
]
|
||||||
return br
|
return br
|
||||||
|
|
||||||
|
@ -151,7 +151,7 @@ class WSJ(BasicNewsRecipe):
|
|||||||
br.addheaders += [
|
br.addheaders += [
|
||||||
('Accept-Encoding', 'gzip'),
|
('Accept-Encoding', 'gzip'),
|
||||||
('cache-control', 'no-cache'),
|
('cache-control', 'no-cache'),
|
||||||
('x-api-key', ('e''b''2''4''0''8''c''d''2''7''f''8''9''1''3''d''4''2''1''f''a''3''d''5''c''3''d''0''7''c''c''f''0''3''4''c''b''4''4''8')),
|
('x-api-key', ('e''b''2''4''0''8''c''d''2''7''f''8''9''1''3''d''4''2''1''f''a''3''d''5''c''3''d''0''7''c''c''f''0''3''4''c''b''4''4''8')), # noqa: ISC001
|
||||||
]
|
]
|
||||||
return br
|
return br
|
||||||
|
|
||||||
|
@ -47,6 +47,7 @@ unfixable = ['PIE794', 'ISC001']
|
|||||||
[lint.per-file-ignores]
|
[lint.per-file-ignores]
|
||||||
"recipes/*" = ['UP']
|
"recipes/*" = ['UP']
|
||||||
"manual/plugin_examples/*" = ['UP']
|
"manual/plugin_examples/*" = ['UP']
|
||||||
|
"setup/changelog.py" = ['ISC001']
|
||||||
"setup/commands.py" = ['RUF022']
|
"setup/commands.py" = ['RUF022']
|
||||||
"src/calibre/*" = ['UP031']
|
"src/calibre/*" = ['UP031']
|
||||||
"src/calibre/customize/__init__.py" = ['RET501']
|
"src/calibre/customize/__init__.py" = ['RET501']
|
||||||
|
@ -58,7 +58,7 @@ class HeuristicProcessor:
|
|||||||
return '<h2>'+chap+'</h2>\n'
|
return '<h2>'+chap+'</h2>\n'
|
||||||
else:
|
else:
|
||||||
delete_whitespace = re.compile(r'^\s*(?P<c>.*?)\s*$')
|
delete_whitespace = re.compile(r'^\s*(?P<c>.*?)\s*$')
|
||||||
delete_quotes = re.compile(''''"''')
|
delete_quotes = re.compile(''''"''') # noqa: RUF039
|
||||||
txt_chap = delete_quotes.sub('', delete_whitespace.sub(r'\g<c>', html2text(chap)))
|
txt_chap = delete_quotes.sub('', delete_whitespace.sub(r'\g<c>', html2text(chap)))
|
||||||
txt_title = delete_quotes.sub('', delete_whitespace.sub(r'\g<c>', html2text(title)))
|
txt_title = delete_quotes.sub('', delete_whitespace.sub(r'\g<c>', html2text(title)))
|
||||||
self.html_preprocess_sections = self.html_preprocess_sections + 1
|
self.html_preprocess_sections = self.html_preprocess_sections + 1
|
||||||
|
Loading…
x
Reference in New Issue
Block a user