Files
deepseek-harness/packages/util
imccyu 674a1e95a3 fix(api): rename the failure marker, harden cross-realm discrimination, and mark the packed-record violation
- protocol: isDSHRemoteGatewayError -> isDSHRemoteError (the class is
  protocol-wide, not Gateway-specific); remoteErrorOf drops its
  instanceof Error precondition and tests the marker plus a string code
  structurally, so a marked failure from another realm no longer reads
  as a local defect.
- session-controller: the live-follow packed-record protocol violation
  now throws a marked RemoteError('gateway/internal'), landing the
  session in openState=error instead of an unhandled rejection;
  pinned at the transport and session levels.
- util-time: correct the invariant companion's @module name.
- regenerate the tool-cordis catalog for the marker rename.
2026-08-29 03:12:43 +08:00
..
2026-08-28 00:50:12 +08:00
2026-08-28 00:50:12 +08:00
2026-08-28 00:50:12 +08:00
2026-08-28 00:50:12 +08:00
2026-08-28 00:50:12 +08:00

description, kind
description kind
Package map for the zero-dependency utility family: atomic file writes, branded ids, harness home paths, the launch environment, native commands, output retention, time zones, and timeouts. package-group

util/ — zero-dependency shared utilities

English | 中文

Summary

The util/ group gives capability packages shared mechanical primitives instead of duplicate implementations. It covers atomic writes, branded ids, UUIDs, Harness-home paths, launch environments, native commands, output retention, time-zone canonicalization, and timeout handling. Every package here is a library: it registers no service or event, and the consuming capability retains the business semantics.

Table of Contents


Packages

Each package provides one primitive; open a package page for how to use it.

Package Role
brand/ Compile-time-only nominal brands for ids that cross package boundaries
crypto/ Mints RFC 9562 v4 UUIDs from the cross-runtime crypto.getRandomValues primitive
home-paths/ Resolves the single Harness home and joins shared user-data paths
launch-environment/ Frozen launch environment that remembers which layer supplied each value
atomic-write/ Atomic file replacement and cross-process writer locking
native-command/ Runs host-native commands directly, never through a shell string
workspace-path/ Provides browser-safe Workspace path and display helpers
output-retention/ Bounds model-facing output and reports exact omission metadata
time/ Validates and canonicalizes a caller-reported IANA time zone
timeout/ Deadline arithmetic, signal fusion, and timeout-versus-cancel classification

Dev Note

Working context for maintainers — click to expand

None.