Files
deepseek-harness/packages/telemetry
kingwl d398eda432 fix(telemetry): join overlapping flush hints; contain adoption replay per event
Second review round, both pinned red-first:

- Overlapping turn-boundary flush hints now JOIN the outstanding flush
  promise (Promise.all) instead of displacing it: the SDK's
  concurrent-flush guard resolves an overlapping forceFlush()
  immediately, so retaining only the latest promise let shutdown()
  proceed while the first export was still in flight — the same silent
  drop the single-flush fix closed.
- Adoption replay contains failures per event, matching the firehose:
  one rejected record is withheld fail-closed while the rest of the
  historical log still hands off. Wrapping the whole loop let a single
  failure silently skip the remainder on an already-adopted session.
2026-07-25 03:48:32 +08:00
..

telemetry/

Outbound session reporting: the telemetry seam plus its OpenTelemetry backend. The design — the boundary axiom (the harness's aspect ends at emit(); delivery is the reporting SDK's), the telemetry/redact waterfall (deployment-mounted rules; the seam ships none), the fixed chunk projection, the handoff cursor, and the operational-record channel — is pinned in the revival Agent Note.

Package Role
@deepseek-ai/dsh-session-telemetry The seam: capture points, projection, redaction, handoff cursor, ops signals, and the minimal backend contract (emit/flush?/shutdown).
@deepseek-ai/dsh-session-telemetry-otel The backend a deployment loads: the OTel JS SDK's log pipeline (LoggerProvider + BatchLogRecordProcessor + OTLP/HTTP exporter), configured verbatim through passthroughs.