Utilities¶
Utils¶
-
papermill.utils.chdir(path)¶ Change working directory to path and restore old path on exit.
path can be None in which case this is a no-op.
-
papermill.utils.merge_kwargs(caller_args, **callee_args)¶ Merge named argument.
Function takes a dictionary of caller arguments and callee arguments as keyword arguments Returns a dictionary with merged arguments. If same argument is in both caller and callee arguments the last one will be taken and warning will be raised.
Parameters: - caller_args (dict) – Caller arguments
- **callee_args – Keyword callee arguments
Returns: args – Merged arguments
Return type:
-
papermill.utils.remove_args(args=None, **kwargs)¶ Remove arguments from kwargs.
Parameters: - args (list) – Argument names to remove from kwargs
- **kwargs – Arbitrary keyword arguments
Returns: kwargs – New dictionary of arguments
Return type:
-
papermill.utils.retry(num)¶
Exceptions¶
-
exception
papermill.exceptions.AwsError¶ Raised when an AWS Exception is encountered.
-
exception
papermill.exceptions.FileExistsError¶ Raised when a File already exists on S3.
-
exception
papermill.exceptions.PapermillException¶ Raised when an exception is encountered when operating on a notebook.
-
exception
papermill.exceptions.PapermillExecutionError(cell_index, exec_count, source, ename, evalue, traceback)¶ Raised when an exception is encountered in a notebook.
-
exception
papermill.exceptions.PapermillMissingParameterException¶ Raised when a parameter without a value is required to operate on a notebook.
-
exception
papermill.exceptions.PapermillOptionalDependencyException¶ Raised when an exception is encountered when an optional plugin is missing.
-
exception
papermill.exceptions.PapermillParameterOverwriteWarning¶ Callee overwrites caller argument to pass down the stream.
-
exception
papermill.exceptions.PapermillRateLimitException¶ Raised when an io request has been rate limited
-
exception
papermill.exceptions.PapermillWarning¶ Base warning for papermill.
-
papermill.exceptions.missing_dependency_generator(package, dep)¶
-
papermill.exceptions.missing_environment_variable_generator(package, env_key)¶
Log¶
Sets up a logger