ssapy_toolkit.IO.workspace_io

Functions

load_workspace([filename, into_globals])

Load variables from a JSON file back into the workspace.

save_workspace([filename, exclude])

Save all variables from the current workspace to a JSON file.

ssapy_toolkit.IO.workspace_io.load_workspace(filename='workspace.json', into_globals=True)[source]

Load variables from a JSON file back into the workspace.

Parameters:

filenamestr, optional

Name of the file to load from (default: ‘workspace.json’)

into_globalsbool, optional

If True, load variables into the caller’s global scope (default: True) If False, return them as a dictionary

Returns:

dict : Dictionary of loaded variables

ssapy_toolkit.IO.workspace_io.save_workspace(filename='workspace.json', exclude=None)[source]

Save all variables from the current workspace to a JSON file.

Parameters:

filenamestr, optional

Name of the file to save to (default: ‘workspace.json’)

excludelist, optional

List of variable names to exclude from saving

Returns:

dict : Dictionary containing saved variables and metadata