hpcflow.sdk.monitoring.columns.RenderContext#

class hpcflow.sdk.monitoring.columns.RenderContext(full=False, view='counts', include_loop_skipped=False, group_elements=True, group_iterations=True, list_only=False, use_cache=False, action_widths=None, element_widths=None, action_summaries=<factory>, compact_actions=<factory>, compact_elements=<factory>, element_summaries=<factory>, display_timezone=<factory>, current_local_time=<factory>, status_icon_width=0)#

Bases: object

Shared formatting settings and memoized element summaries for one table.

Capture the current local time once so every datetime cell uses the same reference for omitting timezone suffixes. Action and element widths are shared across submissions, keeping full-detail status icons aligned.

Methods

actions

Memoize visible actions, qualifying running states by submission activity.

elements

Return the element summary for a record, computing it at most once.

format_datetime

Format a timestamp using this table's display zone and local-time snapshot.

Attributes

Parameters:
action_summaries: dict[int, ActionSummary]#
action_widths: ActionColumnWidths | None#
actions(record)#

Memoize visible actions, qualifying running states by submission activity.

Parameters:

record (SubmissionRecord)

Return type:

ActionSummary

compact_actions: set[int]#
compact_elements: set[int]#
current_local_time: datetime#
display_timezone: tzinfo#
element_summaries: dict[int, ActionSummary]#
element_widths: ActionColumnWidths | None#
elements(record)#

Return the element summary for a record, computing it at most once.

The loop-skip visibility policy is applied before aggregating actions across iterations. The cache is scoped to this render context and keyed by record identity.

Parameters:

record (SubmissionRecord)

Return type:

ActionSummary

format_datetime(value, *, same_date_as=None, align_omitted_date=False)#

Format a timestamp using this table’s display zone and local-time snapshot.

Parameters:
  • value (str)

  • same_date_as (str | None)

  • align_omitted_date (bool)

Return type:

str

full: bool#
group_elements: bool#
group_iterations: bool#
include_loop_skipped: bool#
list_only: bool#
status_icon_width: int#
use_cache: bool#
view: Literal['counts', 'tasks', 'detail', 'auto']#