mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
pep8
This commit is contained in:
parent
1f2293fc11
commit
be8202a30f
@ -82,6 +82,7 @@ class Hyphenator:
|
||||
pieces.append('')
|
||||
return pieces
|
||||
|
||||
|
||||
patterns = (
|
||||
# Knuth and Liang's original hyphenation patterns from classic TeX.
|
||||
# In the public domain.
|
||||
|
@ -14,6 +14,7 @@ def find_tests():
|
||||
base = os.path.dirname(os.path.abspath(__file__))
|
||||
return find_tests_in_dir(base)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
try:
|
||||
import init_calibre # noqa
|
||||
|
@ -306,6 +306,7 @@ class _CompileParser(_Parser):
|
||||
else:
|
||||
self.error(_('expression is not function or constant'))
|
||||
|
||||
|
||||
compile_counter = 0
|
||||
|
||||
|
||||
@ -547,6 +548,7 @@ class ValidateFormatter(TemplateFormatter):
|
||||
self.book = Metadata('')
|
||||
return self.vformat(x, [], {})
|
||||
|
||||
|
||||
validation_formatter = ValidateFormatter()
|
||||
|
||||
|
||||
@ -561,6 +563,6 @@ class EvalFormatter(TemplateFormatter):
|
||||
key = key.lower()
|
||||
return kwargs.get(key, _('No such variable ') + key)
|
||||
|
||||
|
||||
# DEPRECATED. This is not thread safe. Do not use.
|
||||
eval_formatter = EvalFormatter()
|
||||
|
||||
|
@ -271,6 +271,7 @@ def makeRequests(callable, args_list, callback=None, exc_callback=None):
|
||||
# USAGE EXAMPLE
|
||||
################
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
import random
|
||||
import time
|
||||
|
Loading…
x
Reference in New Issue
Block a user