Skip to main content

LocalShellTaskState

Struct LocalShellTaskState 

Source
pub struct LocalShellTaskState {
Show 22 fields pub id: String, pub task_type: String, pub status: TaskStatus, pub description: String, pub tool_use_id: Option<String>, pub start_time: u64, pub end_time: Option<u64>, pub total_paused_ms: Option<u64>, pub output_file: String, pub output_offset: u64, pub notified: bool, pub type: String, pub command: String, pub result: Option<ShellCommandResult>, pub completion_status_sent_in_attachment: bool, pub shell_command: Option<Box<dyn ShellCommandTrait>>, pub unregister_cleanup: Option<Box<dyn FnOnce()>>, pub cleanup_timeout_id: Option<u64>, pub last_reported_total_lines: usize, pub is_backgrounded: Option<bool>, pub agent_id: Option<AgentId>, pub kind: Option<BashTaskKind>,
}
Expand description

State for a local shell (bash) task. Extracted from LocalShellTask.tsx so non-React consumers (stopTask.ts via print.rs) don’t pull React/ink into the module graph.

Fields§

§id: String§task_type: String§status: TaskStatus§description: String§tool_use_id: Option<String>§start_time: u64§end_time: Option<u64>§total_paused_ms: Option<u64>§output_file: String§output_offset: u64§notified: bool§type: String

Keep as ‘local_bash’ for backward compatibility with persisted session state

§command: String§result: Option<ShellCommandResult>§completion_status_sent_in_attachment: bool§shell_command: Option<Box<dyn ShellCommandTrait>>§unregister_cleanup: Option<Box<dyn FnOnce()>>§cleanup_timeout_id: Option<u64>§last_reported_total_lines: usize

Track what we last reported for computing deltas (total lines from TaskOutput)

§is_backgrounded: Option<bool>

Whether the task has been backgrounded (false = foreground running, true = backgrounded)

§agent_id: Option<AgentId>

Agent that spawned this task. Used to kill orphaned bash tasks when the agent exits (see kill_shell_tasks_for_agent). None = main thread.

§kind: Option<BashTaskKind>

UI display variant. ‘monitor’ shows description instead of command, ‘Monitor details’ dialog title, distinct status bar pill.

Trait Implementations§

Source§

impl Debug for LocalShellTaskState

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more