gsplot.OutputError#

exception OutputError(message, *, committed_paths=())#

Bases: GsplotError

Raised when figure output or display cannot be completed.

Parameters:
  • message (str) – Public-safe explanation of the failed output operation.

  • committed_paths (Iterable[Path]) – Absolute final paths already replaced before the failure. The value defaults to an empty immutable tuple.

Variables:

committed_paths – Immutable tuple of final paths already committed by the operation.

Return type:

None

Examples

>>> from pathlib import Path
>>> import gsplot as gs
>>> error = gs.OutputError("commit failed", committed_paths=(Path("figure.png"),))
>>> len(error.committed_paths)
1
__init__(message, *, committed_paths=())#

Initialize one public-safe output failure.

Parameters:
  • message (str)

  • committed_paths (Iterable[Path])

Return type:

None