libstp.step.annotation

Attributes

T

F

Classes

DslMeta

Discovery metadata attached by @dsl to steps and factories.

Functions

dsl(…)

Mark a class or function as part of the DSL.

Module Contents

class libstp.step.annotation.DslMeta

Discovery metadata attached by @dsl to steps and factories.

hidden: bool = False
name: str | None = None
tags: tuple[str, Ellipsis] = ()
libstp.step.annotation.T
libstp.step.annotation.F
libstp.step.annotation.dsl(_target: T) T
libstp.step.annotation.dsl(_target: F) F
libstp.step.annotation.dsl(_target: None = None, *, hidden: bool = False, name: str | None = None, tags: list[str] | tuple[str, Ellipsis] | None = None) Callable[[T | F], T | F]

Mark a class or function as part of the DSL.

Usage:

@dsl class X(Step): …

@dsl(hidden=True, name=”TurnLeft”, tags=[“movement”, “rotation”]) class Y(Step): …

@dsl(name=”Wait”, tags=[“timing”]) def wait_seconds(seconds: float) -> WaitStep:

return WaitStep(seconds)

Parameters:
  • hidden – If True, hide from auto-discovery/UI.

  • name – Custom display name (defaults to class/function name).

  • tags – List of tags for grouping in web UI.