agent-afk 5.299.7 → 5.299.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,16 @@
1
+ import type { ProviderEvent, ProviderQuery } from '../provider.js';
2
+ import type { AgentConfig } from '../types.js';
3
+ import type { JournalLifecycle } from './journal-lifecycle.js';
4
+ import type { SessionShutdown } from './session-shutdown.js';
5
+ import type { SessionStateManager } from './session-state.js';
6
+ export interface CloseDrainDeps {
7
+ readonly abortController: AbortController;
8
+ readonly stateManager: SessionStateManager;
9
+ readonly providerQuery: ProviderQuery;
10
+ readonly providerIterator: AsyncIterator<ProviderEvent>;
11
+ readonly initPromise: Promise<void> | null;
12
+ readonly journal: JournalLifecycle;
13
+ readonly shutdown: SessionShutdown;
14
+ readonly env: AgentConfig['env'];
15
+ }
16
+ export declare function drainAndFinalizeClose(deps: CloseDrainDeps): Promise<void>;
@@ -11,6 +11,7 @@ export declare class SessionTmpdir {
11
11
  readonly root: string;
12
12
  private readonly parent;
13
13
  private owned;
14
+ private ensured;
14
15
  constructor(dir: string, root: string, parent: SessionTmpdir | undefined);
15
16
  get isOwned(): boolean;
16
17
  ensure(): boolean;
@@ -2,6 +2,7 @@ import type { PeerInboxNotifier } from './peer-inbox-notifier.js';
2
2
  import { AdmissionQueue } from '../../../agent/peer/admission-queue.js';
3
3
  import type { InteractiveCtx } from './shared.js';
4
4
  import type { InputSurface } from '../../input/input-surface.js';
5
+ import { type InjectionSource } from './loop-iteration.injections.js';
5
6
  export interface BoundaryCompositor {
6
7
  hasPendingSubmission(): boolean;
7
8
  }
@@ -18,6 +19,7 @@ export interface PeerBoundaryOpts {
18
19
  export declare function installPeerBoundary(opts: PeerBoundaryOpts): () => void;
19
20
  export declare function reinstallPeerBoundary(opts: PeerBoundaryOpts, prevDispose: (() => void) | undefined): () => void;
20
21
  export declare function drainAdmissionQueueFallback(text: string, q: AdmissionQueue): string;
22
+ export declare function applyDeferPeers(runText: string, queuedHumanTurn: boolean, surface: Pick<InputSurface, 'getCompositor'>, shellPassthrough: InjectionSource, bgResultNotifier: InjectionSource, peerNotifier: InjectionSource, admissionQueue: AdmissionQueue): string;
21
23
  export declare function setupPeerBoundary(ctx: InteractiveCtx, surface: InputSurface, peerNotifier: PeerInboxNotifier, isQueuedHumanTurn: () => boolean): {
22
24
  admissionQueue: AdmissionQueue;
23
25
  reinstall: () => void;