Raised (or returned) when undo is called on a record that cannot be
rewound.
The reason field says which rule refused, so callers can branch without
matching on message text:
:undo_not_enabled— the workflow has noundoblock.:no_history— the record's transition log has no state change to undo.:not_undoable— the last state change came from a transition that is not markedundoable?: true. Automatic steps, timeouts, error paths and the initial row all land here.:window_expired— the transition is older than the configuredwithin.:different_actor—same_actor?is set and the actor differs from the one recorded on the transition.:no_actor—same_actor?is set and either the caller or the recorded transition has no actor.:stale— the record moved on between reading the log and writing, so the row being undone is no longer the head.
Summary
Functions
Create an Elixir.AshWorkflow.Errors.UndoNotPermitted without raising it.
Types
Functions
@spec exception(opts :: Keyword.t()) :: %AshWorkflow.Errors.UndoNotPermitted{ __exception__: true, bread_crumbs: term(), class: term(), from_state: term(), path: term(), reason: term(), resource: term(), splode: term(), stacktrace: term(), to_state: term(), vars: term() }
Create an Elixir.AshWorkflow.Errors.UndoNotPermitted without raising it.
Keys
- :reason
- :resource
- :from_state
- :to_state