5050
5151@contextlib .contextmanager
5252def _mp_prefork (
53- plugins : Checkers , options : argparse .Namespace
53+ plugins : Checkers , options : argparse .Namespace ,
5454) -> Generator [None ]:
5555 # we can save significant startup work w/ `fork` multiprocessing
5656 global _mp
@@ -77,7 +77,7 @@ def _mp_run(filename: str) -> tuple[str, Results, dict[str, int]]:
7777 assert _mp is not None , _mp
7878 plugins , options = _mp
7979 return FileChecker (
80- filename = filename , plugins = plugins , options = options
80+ filename = filename , plugins = plugins , options = options ,
8181 ).run_checks ()
8282
8383
@@ -137,7 +137,7 @@ def _job_count(self) -> int:
137137 if utils .is_using_stdin (self .options .filenames ):
138138 LOG .warning (
139139 "The --jobs option is not compatible with supplying "
140- "input using - . Ignoring --jobs arguments."
140+ "input using - . Ignoring --jobs arguments." ,
141141 )
142142 return 0
143143
@@ -252,7 +252,7 @@ def start(self) -> None:
252252 stdin_display_name = self .options .stdin_display_name ,
253253 filename_patterns = self .options .filename ,
254254 exclude = self .exclude ,
255- )
255+ ),
256256 )
257257 self .jobs = min (len (self .filenames ), self .jobs )
258258
@@ -332,11 +332,11 @@ def run_check(self, plugin: LoadedPlugin, **arguments: Any) -> Any:
332332 assert self .processor is not None , self .filename
333333 try :
334334 params = self .processor .keyword_arguments_for (
335- plugin .parameters , arguments
335+ plugin .parameters , arguments ,
336336 )
337337 except AttributeError as ae :
338338 raise exceptions .PluginRequestedUnknownParameters (
339- plugin_name = plugin .display_name , exception = ae
339+ plugin_name = plugin .display_name , exception = ae ,
340340 )
341341 try :
342342 return plugin .obj (** arguments , ** params )
@@ -548,7 +548,7 @@ def handle_newline(self, token_type: int) -> None:
548548 self .run_logical_checks ()
549549
550550 def check_physical_eol (
551- self , token : tokenize .TokenInfo , prev_physical : str
551+ self , token : tokenize .TokenInfo , prev_physical : str ,
552552 ) -> None :
553553 """Run physical checks if and only if it is at the end of the line."""
554554 assert self .processor is not None
@@ -598,7 +598,7 @@ def _try_initialize_processpool(
598598
599599
600600def find_offset (
601- offset : int , mapping : processor ._LogicalMapping
601+ offset : int , mapping : processor ._LogicalMapping ,
602602) -> tuple [int , int ]:
603603 """Find the offset tuple for a single offset."""
604604 if isinstance (offset , tuple ):
0 commit comments