Workspaces¶
- class WorkspaceClient(beaker: Beaker)[source]¶
Methods for interacting with Beaker Workspaces. Accessed via the
Beaker.workspaceproperty.Warning
Do not instantiate this class directly! The
Beakerclient will create one automatically which you can access through the corresponding property.- get(workspace: str | None = None) Workspace[source]¶
- Examples:
>>> with Beaker.from_env() as beaker: ... workspace = beaker.workspace.get(workspace_name)
- Returns:
A
BeakerWorkspaceprotobuf object.- Raises:
BeakerWorkspaceNotFoundif the workspace doesn’t exist.
- create(name: str, *, org: Organization | None = None, description: str | None = None) Workspace[source]¶
- update(workspace: Workspace | None = None, *, name: str | None = None, description: str | None = None, archived: bool | None = None, budget: str | None = None, maximum_workspace_priority: BeakerJobPriority | None = None) Workspace[source]¶
- list(*, org: Organization | None = None, author: User | None = None, workload_author: User | None = None, name_or_description: str | None = None, only_archived: bool = False, sort_order: BeakerSortOrder | None = None, sort_field: Literal['created', 'name', 'recent_workload_activity', 'maximum_workload_priority'] = 'name', include_workspace_size: bool = False, limit: int | None = None) Iterable[Workspace][source]¶