File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -371,7 +371,7 @@ def _get_option_with_source(
371371 # object with a custom configuration
372372
373373 if "." not in dch :
374- raise ImportError (f "Invalid path for configuration hook: { dch } " )
374+ raise ImportError ("Invalid path for configuration hook: {}" . format ( dch ) )
375375
376376 pkg_parts = dch .split ("." )
377377 module_path = "." .join (pkg_parts [:- 1 ])
@@ -382,12 +382,12 @@ def _get_option_with_source(
382382 try :
383383 mod = importlib .import_module (module_path )
384384 except (ImportError , AttributeError ):
385- raise ImportError (f "Unable to import module { module_path } " )
385+ raise ImportError ("Unable to import module {}" . format ( module_path ) )
386386 func = getattr (mod , function_name , None )
387387
388388 if not func :
389- raise ImportError (f "No function found with name { function_name } in module "
390- f" { module_path } !" )
389+ raise ImportError ("No function found with name {} in module {}! "
390+ . format ( function_name , module_path ) )
391391
392392 # Call the function
393393 func ()
You can’t perform that action at this time.
0 commit comments