langgoap.run_guards_sync#
- run_guards_sync(guards, action, world_state)[source]#
Run all synchronous guards and return all
GuardResultobjects.Async-only guards are skipped with a warning. Per-guard exceptions are caught and converted into a
WARNresult so a bad guard never crashes the executor.- Parameters:
guards (list[ActionGuard | AsyncActionGuard]) – Guards to run.
action (ActionSpec) – The action about to execute.
world_state (dict[str, Any]) – Current world state snapshot.
- Returns:
GuardResultfor every guard that ran.- Return type:
list[GuardResult]