pub struct QueuedApproval {
pub child_agent_id: String,
pub tool: String,
pub subject: Option<String>,
pub queued_at_ms: i64,
}Expand description
A queued approval request from a background_prompts = "parent" child,
surfaced via Agent::pending_child_approvals (§2.2 C6 “parent-surfaced
queue”). This struct is ALWAYS a record for the parent to inspect/audit
(never a pending decision the parent’s answer changes retroactively) —
but what actually answers the underlying call depends on which
PermissionsApprovalHandler Agent::run_spawn_subagent installed for
the child:
- the DEFAULT
ParentQueueApprovalHandler(no TUI factory installed) resolves every request toDenyimmediately, THEN records it here — “queued” in name only, never actually blocking (P5-3’s shipped, never-blocking posture, unchanged). - P5-4’s
crate::tui::TuiChildApprovalHandler(installed viacrate::agent::Agent::set_child_approval_handler_factory) records the SAME entry here for audit purposes, but the underlying call genuinely BLOCKS until a TUI operator answers it — which may resolveAllow/AllowForSession, not onlyDeny. So: don’t assume every entry here was already denied — check the actual outcome the caller observed (or the handler installed for this session) before treating this queue as “purely historical, all denied.”
Fields§
§child_agent_id: StringWhich child raised this request.
tool: StringThe tool it tried to call.
subject: Option<String>The canonicalized command/path subject, if any.
queued_at_ms: i64Unix-ms wall-clock time it was queued.
Trait Implementations§
Source§impl Clone for QueuedApproval
impl Clone for QueuedApproval
Source§fn clone(&self) -> QueuedApproval
fn clone(&self) -> QueuedApproval
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for QueuedApproval
impl RefUnwindSafe for QueuedApproval
impl Send for QueuedApproval
impl Sync for QueuedApproval
impl Unpin for QueuedApproval
impl UnsafeUnpin for QueuedApproval
impl UnwindSafe for QueuedApproval
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more