Skip to content

Commit

Permalink
Improve type hints and re-format docstring
Browse files Browse the repository at this point in the history
  • Loading branch information
tmadlener committed Feb 28, 2024
1 parent a554b1e commit dce6c99
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions k4FWCore/python/k4FWCore/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@


def import_from(
filename: os.PathLike,
filename: Union[str, os.PathLike],
module_name: Optional[str] = None,
global_vars: Optional[Dict[str, Any]] = None,
) -> Any:
Expand All @@ -42,11 +42,9 @@ def import_from(
Args:
filename (str): The path to the file from which to import the module.
module_name (Optional[str]): The name to assign to the module. Defaults
to None, in which case the filename is used
as the module name.
to None, in which case the filename is used as the module name.
global_vars (Optional[Dict[str, Any]]): A dictionary of global variables
to inject into the module's
namespace. Defaults to None.
to inject into the module's namespace. Defaults to None.
Returns:
Any: The imported module with the specified modifications.
Expand Down

0 comments on commit dce6c99

Please sign in to comment.