Commit Graph
7 Commits
Author SHA1 Message Date
Tianyi Cui 4643e0de10 test(windows): make coverage fixtures portable 2026-07-22 13:10:48 +08:00
Turtle fac3fc090f fix(paths): treat empty DSH_HOME as unset; isolate telemetry env test
Review fixes for #462:
- resolveDshHome now treats an empty or whitespace-only $DSH_HOME as
  unset, so a blank override never resolves the home to cwd via
  resolve(''). Restores the guard telemetry's old resolver carried.
- The default-env telemetry test asserts only that globalConfigDir()
  returns an absolute path, so a machine DSH_HOME without a .dsh suffix
  cannot break it.
2026-07-21 14:43:38 +08:00
Turtle 92e0d0e04f refactor(paths): collapse harness home resolution into one resolver
Delete @deepseek-ai/dsh-home and make dsh-paths the sole owner of the
single-root harness home ($DSH_HOME || ~/.dsh). Migrate tool-bash,
skill-local, and agent-spine-demo off dsh-home, and fold telemetry's
divergent globalConfigDir onto the shared resolver, dropping its second
XDG/APPDATA policy and the deepseek-harness namespace so the anonymous
id lives under the harness home. Add dshHomeDisplay() for symbolic
user-facing paths, replacing workspace-context's bespoke check.
2026-07-21 13:52:00 +08:00
imccyu 7a5d3ae5ce fix(telemetry): stop bearer redaction from eating plain prose
The bearer rule matched any 8+ run of letters after the word, so
package.json prose like "uses bearer authentication" lost its
following word to the placeholder. Real bearer credentials always
carry a digit; require one in the candidate token.
2026-07-18 22:10:22 +08:00
imccyu e674f4c20e fix(telemetry): withhold package.json when cordis.yml is absent
buildTelemetryPayload read the two reported files independently, so a
dsh-sdk command mistakenly run in an arbitrary non-SDK directory (no
cordis.yml, e.g. any unrelated repo) still uploaded that directory's
package.json — dependency names and metadata of a project that never
opted into the SDK toolchain. Gate the manifest on cordis.yml presence:
without the config the directory is not an SDK project and its manifest
is not ours to report. Consent semantics are unchanged.
2026-07-18 22:10:22 +08:00
imccyu a66b98d270 fix(telemetry): report unless telemetry entry is explicitly disabled
Per ccyu's decision (option A), remove the consent asymmetry in ConsentResolver:
telemetry is OFF only when cordis.yml has a telemetry entry with disabled: true.
A cordis.yml with no telemetry entry now reports (allowWhenEntryAbsent defaults
to true) rather than denying. No cordis.yml, an enabled entry, and DO_NOT_TRACK/CI
are unchanged. Both no-config and absent-entry defaults stay configurable.

Updates the module/README docs and the unit tests (file-present-but-no-entry and
non-object/non-sequence roots now report). Per-file 100% coverage holds.
2026-07-18 16:11:25 +08:00
imccyu fe668a6dfe feat(telemetry): greenfield dsh-sdk telemetry modules
Add @deepseek-ai/dsh-telemetry, a launcher-side (non-plugin) library for the
ConsentResolver (parses cordis.yml consent + DO_NOT_TRACK/CI), buildTelemetryPayload
(redacted cordis.yml + package.json full content, never .env), getOrCreateAnonymousId
(random UUID in a per-machine global config file), and TelemetryReporter
(fire-and-forget, never blocks or crashes the command).

Endpoint is a fixed .invalid placeholder pending the real endpoint. Launcher
dispatch wiring and the helper feature-catalog entry are intentionally out of
scope. Registers the package in tsconfig references, the module graph, and the
README model-experience audit map. Per-file 100% coverage.
2026-07-18 16:11:25 +08:00