fix(rivetkit-napi): demote bridge error decode log from warn to debug#4983
Conversation
|
🚅 Deployed to the rivet-pr-4983 environment in rivet-frontend
|
|
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. |
Code ReviewOverviewThis PR reduces log noise across three sites: demotes a successfully-decoded bridge error log from The intent is clear and the changes are generally low-risk. One correctness concern worth addressing before merge. Issues[Bug] The original code handled two cases: (a) signal already aborted → call The fix separates the two concerns: if (request.signal.aborted) {
abort();
} else if (needsAbortListener) {
request.signal.addEventListener("abort", abort, { once: true });
}This preserves the fast path (no listener churn for metadata polls) while still short-circuiting pre-aborted requests. Feedback
Correct. Successful decoding of an encoded bridge error is normal operation; surfacing it as
Well-structured. One minor note: both benign and non-benign paths swallow the rejection (no re-throw from Comment style Both added comments follow project conventions (complete sentences, no em dashes, no delta documentation). Good. |

Description
Please include a summary of the changes and the related issue. Please also include relevant motivation and context.
Type of change
How Has This Been Tested?
Please describe the tests that you ran to verify your changes.
Checklist: