fix(protocol): drop stack traces from DCL error logs#3992
Merged
Conversation
Log message + cause chain via Diagnostic.errorMessage instead of the full error object for vendor-info update, OTA image validation, and OTA file read failures. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
This PR reduces log noise in the DCL (Distributed Compliance Ledger) integration by avoiding multi-line stack traces for routine/transient failures, logging a concise message plus the cause chain via Diagnostic.errorMessage(...) instead.
Changes:
- Update
DclVendorInfoServiceto log vendor update failures usingDiagnostic.errorMessage(asError(error))instead of logging the raw error object. - Update
DclOtaUpdateServiceto log OTA validation/re-download and OTA file read failures usingDiagnostic.errorMessage(asError(error))(and add the neededasErrorimport).
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| packages/protocol/src/dcl/DclVendorInfoService.ts | Replace raw error logging with Diagnostic.errorMessage(asError(...)) for vendor update failures to avoid stack traces. |
| packages/protocol/src/dcl/DclOtaUpdateService.ts | Replace raw error logging with Diagnostic.errorMessage(asError(...)) for OTA validation and OTA file read failures; add asError import. |
Contributor
|
Tick the box to add this pull request to the merge queue (same as
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
DCL download/update errors logged the full error object, dumping multi-line stack traces for routine transient failures (e.g. DCL timeouts). Now they log the message + cause chain via
Diagnostic.errorMessage, no stack.Before:
After:
Changes
DclVendorInfoService.ts— vendor-info update failureDclOtaUpdateService.ts— OTA image validation/re-download + OTA file read failures🤖 Generated with Claude Code