yera.ui.rendering.views.sessions

Rendering for the Sessions exploration screen.

Symbols

def classify_sessions — Classify ordered session records without changing their order.
def render_live_sessions — Render active sessions for the canonical Live screen.
def render_mobile_session_detail — Render persisted session metadata as a pushed mobile screen.
def render_session_sidebar — Render persisted metadata and navigation for one selected session.
def render_sessions_home — Render persisted sessions as main-screen navigation.
class SessionGroups — Sessions grouped for live, historical, and offline presentation.
class SessionViewMode — Supported Sessions history presentations.

classify_sessions

classify_sessions(
    records: list[SessionRecord],
    available_app_ids: Collection[str],
) → SessionGroups

Classify ordered session records without changing their order.

Parameters

records
type: list[SessionRecord]

Session records in their intended display order.

available_app_ids
type: Collection[str]

Apps currently available on this server.

Returns

type: SessionGroups

Session records grouped by availability and persisted lifecycle state.

render_live_sessions

render_live_sessions(
    apps: dict[str, AppFunctionWrapper],
    live_by_app: dict[str, list[SessionRecord]],
) → TrustedHTML

Render active sessions for the canonical Live screen.

render_mobile_session_detail

render_mobile_session_detail(
    record: SessionRecord,
    app_name: str,
    app_available: bool,
) → TrustedHTML

Render persisted session metadata as a pushed mobile screen.

render_session_sidebar

render_session_sidebar(
    record: SessionRecord,
    app_name: str,
    app_available: bool,
) → TrustedHTML

Render persisted metadata and navigation for one selected session.

Parameters

record
type: SessionRecord

Persisted session being inspected.

app_name
type: str

Human-readable app name or its stored identifier.

app_available
type: bool

Whether the app is currently registered on this server.

Returns

type: TrustedHTML

Contextual session-inspector HTML.

render_sessions_home

render_sessions_home(
    records: list[SessionRecord],
    apps: dict[str, AppFunctionWrapper],
    selected_session_id: str = '',
    mode: SessionViewMode = SessionViewMode.CHRONOLOGICAL,
) → TrustedHTML

Render persisted sessions as main-screen navigation.

Parameters

records
type: list[SessionRecord]

Sessions ordered for display.

apps
type: dict[str, AppFunctionWrapper]

Apps currently available on this server.

selected_session_id
type: str = ''

Session to mark as selected, if any.

mode
type: SessionViewMode = SessionViewMode.CHRONOLOGICAL

History ordering and grouping presentation.

Returns

type: TrustedHTML

Main-screen HTML for session exploration.

SessionGroups

Sessions grouped for live, historical, and offline presentation.

SessionViewMode

Inherits: StrEnum

Supported Sessions history presentations.