@@ -212,7 +212,7 @@ def check_exposure(self, request):
212
212
213
213
class HtmlWrapperHandler (WrapperHandler ):
214
214
global_type : ClassVar [Optional [str ]] = None
215
- headers = [(' Content-Type' , ' text/html' )]
215
+ headers = [(" Content-Type" , " text/html" )]
216
216
217
217
def check_exposure (self , request ):
218
218
if self .global_type is not None :
@@ -232,7 +232,7 @@ def _meta_replacement(self, key, value):
232
232
return '<meta name="timeout" content="long">'
233
233
if key == "title" :
234
234
value = value .replace ("&" , "&" ).replace ("<" , "<" )
235
- return ' <title>%s</title>' % value
235
+ return " <title>%s</title>" % value
236
236
return None
237
237
238
238
def _script_replacement (self , key , value ):
@@ -560,7 +560,7 @@ class ShadowRealmInAudioWorkletHandler(HtmlWrapperHandler):
560
560
561
561
562
562
class BaseWorkerHandler (WrapperHandler ):
563
- headers = [(' Content-Type' , ' text/javascript' )]
563
+ headers = [(" Content-Type" , " text/javascript" )]
564
564
565
565
def _meta_replacement (self , key , value ):
566
566
return None
@@ -738,7 +738,7 @@ def __init__(self, inject_script = None):
738
738
self .extra = []
739
739
self .inject_script_data = None
740
740
if inject_script is not None :
741
- with open (inject_script , 'rb' ) as f :
741
+ with open (inject_script , "rb" ) as f :
742
742
self .inject_script_data = f .read ()
743
743
744
744
self .mountpoint_routes = OrderedDict ()
@@ -848,7 +848,7 @@ def start(self, init_func, host, port, paths, routes, bind_address, config, log_
848
848
self .proc = self .mp_context .Process (target = self .create_daemon ,
849
849
args = (init_func , host , port , paths , routes , bind_address ,
850
850
config , log_handlers , dict (** os .environ )),
851
- name = ' %s on port %s' % (self .scheme , port ),
851
+ name = " %s on port %s" % (self .scheme , port ),
852
852
kwargs = kwargs )
853
853
self .proc .daemon = True
854
854
self .proc .start ()
@@ -1429,10 +1429,10 @@ def run(config_cls=ConfigBuilder, route_builder=None, mp_context=None, log_handl
1429
1429
if kwargs .get ("alias_file" ):
1430
1430
with open (kwargs ["alias_file" ]) as alias_file :
1431
1431
for line in alias_file :
1432
- alias , doc_root = (x .strip () for x in line .split (',' ))
1432
+ alias , doc_root = (x .strip () for x in line .split ("," ))
1433
1433
config ["aliases" ].append ({
1434
- ' url-path' : alias ,
1435
- ' local-dir' : doc_root ,
1434
+ " url-path" : alias ,
1435
+ " local-dir" : doc_root ,
1436
1436
})
1437
1437
1438
1438
if route_builder is None :
0 commit comments