2026-10-16 11:48:59 +08:00
|
|
|
import type { ArtifactResourceScope } from "../../src/artifacts/ArtifactResourceScope.js";
|
2026-10-21 00:09:34 +08:00
|
|
|
import type { RetainedResourceScope } from "../../src/application/AnalysisProvider.js";
|
2026-10-18 20:46:25 +08:00
|
|
|
|
|
|
|
|
/** Complete a prerequisite operation, including retained cleanup on failure. */
|
|
|
|
|
export function withVerifierResourceOwner<T>(
|
2026-10-21 00:09:34 +08:00
|
|
|
operation: (owner: RetainedResourceScope) => Promise<T>,
|
2026-10-18 20:46:25 +08:00
|
|
|
): Promise<T>;
|
2026-10-16 11:48:59 +08:00
|
|
|
|
|
|
|
|
/** Hash one verifier input and transfer failed-close ownership to its scope. */
|
|
|
|
|
export function hashVerifierFile(
|
|
|
|
|
path: string,
|
|
|
|
|
resources: Pick<ArtifactResourceScope, "retain">,
|
|
|
|
|
): Promise<{ readonly bytes: number; readonly sha256: string }>;
|