Skip to content

fix(listener): improve Discord delivery failure logging - #670

Merged
Abd-Standard merged 1 commit into
Core-Foundry:mainfrom
praizeD10:feature/improve-discord-delivery-logging
Sep 1, 2026
Merged

fix(listener): improve Discord delivery failure logging#670
Abd-Standard merged 1 commit into
Core-Foundry:mainfrom
praizeD10:feature/improve-discord-delivery-logging

Conversation

@praizeD10

Copy link
Copy Markdown
  • Replace duplicate success log with a single, richer delivery log
  • Add classifyHttpStatus() to map status codes to readable categories (rate_limited, auth_error, not_found, client_error, server_error)
  • Add safeReadResponseBody() to capture error bodies with 300-char cap
  • Surface retryAfter header on 429 responses for actionable diagnostics
  • Pass logContext through sendWebhook() so timeout logs carry requestId and eventId for end-to-end traceability
  • Fix sendTestMessage() to log error detail on non-ok responses instead of a bare ok:true/false field
  • Webhook URL and tokens never appear in any log path; only webhookId is logged
  • Update e2e test assertions to match renamed log messages and new field names (httpStatus, httpCategory) in both delivery lifecycle and multi-channel test suites

Overview

Related Issue

Closes #638

Changes

Verification

# e.g.
cd dashboard && npm test
cd listener && npm run typecheck && npm test
cd contract/contracts/hello-world && cargo test

How to Test

Checklist

  • Branch is up to date with main
  • Tests added/updated and all pass locally
  • cargo fmt --all run (if Rust changes)
  • npm run lint passes (if TypeScript changes)
  • Documentation updated if behavior changed

@drips-wave

drips-wave Bot commented Aug 28, 2026

Copy link
Copy Markdown

@praizeD10 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

- Replace duplicate success log with a single, richer delivery log
- Add classifyHttpStatus() to map status codes to readable categories
  (rate_limited, auth_error, not_found, client_error, server_error)
- Add safeReadResponseBody() to capture error bodies with 300-char cap
- Surface retryAfter header on 429 responses for actionable diagnostics
- Pass logContext through sendWebhook() so timeout logs carry requestId
  and eventId for end-to-end traceability
- Fix sendTestMessage() to log error detail on non-ok responses instead
  of a bare ok:true/false field
- Webhook URL and tokens never appear in any log path; only webhookId is logged
- Update e2e test assertions to match renamed log messages and new field
  names (httpStatus, httpCategory) in both delivery lifecycle and
  multi-channel test suites
@praizeD10
praizeD10 force-pushed the feature/improve-discord-delivery-logging branch from 5bc550e to 6562c08 Compare August 30, 2026 12:26
@Abd-Standard
Abd-Standard merged commit 0153215 into Core-Foundry:main Sep 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Improve Discord Delivery Diagnostics

2 participants