nemo_gym.failure_kinds
nemo_gym.failure_kinds
Shared names for why a rollout failed.
Gym describes failures with free text and component-local labels, so the same failure arrives at a collector, a log line and a metric under three different names and cannot be grouped. This module holds the one vocabulary those producers share.
A name says what kind of thing went wrong and nothing else. Whether to retry, whether
the request may be replayed, whether a completed result should be masked, and what to tell
a person are all properties of the occurrence, not of the name — they live on the failure
record, on the verify response, and in failure_reason respectively. Keeping them out is
deliberate: metadata attached to a name goes stale the moment one caller wants to retry
what another caller does not.
Names are low cardinality on purpose. They are safe as a metric label or a span dimension;
failure_reason never is, because it carries occurrence detail and can be unbounded.
This module imports only the standard library so that data tooling can read the vocabulary without installing any server’s requirements.
Module Contents
Functions
Data
API
Whether name is an environment’s own <server>:<kind> extension.
Whether name is part of the shared vocabulary.
Return name unchanged, warning once per unregistered value.
Producers call this at their boundary. It warns rather than raises so a component that still emits an old label stays visible during migration — rejecting it outright would replace an observable wrong name with an invisible dropped failure, which is worse than the problem this vocabulary exists to fix.