Skip to content

fix(chainlib): include response error in ID mismatch logs#2192

Merged
nimrod-teich merged 1 commit into
mainfrom
fix/better_observe_error
Jan 20, 2026
Merged

fix(chainlib): include response error in ID mismatch logs#2192
nimrod-teich merged 1 commit into
mainfrom
fix/better_observe_error

Conversation

@NadavLevi

Copy link
Copy Markdown
Contributor

When a node returns an error (e.g., "Apikey is expired") with an empty/invalid JSON-RPC ID, the ID validation fails with a confusing parsing error. This adds the actual response error message to the log output, making the root cause immediately visible.

Description

Closes: #XXXX


Author Checklist

All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.

I have...

  • read the contribution guide
  • included the correct type prefix in the PR title, you can find examples of the prefixes below:
  • confirmed ! in the type prefix if API or client breaking change
  • targeted the main branch
  • provided a link to the relevant issue or specification
  • reviewed "Files changed" and left comments if necessary
  • included the necessary unit and integration tests
  • updated the relevant documentation or specification, including comments for documenting Go code
  • confirmed all CI checks have passed

Reviewers Checklist

All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.

I have...

  • confirmed the correct type prefix in the PR title
  • confirmed all author checklist items have been addressed
  • reviewed state machine logic, API design and naming, documentation is accurate, tests and test coverage

When a node returns an error (e.g., "Apikey is expired") with an
empty/invalid JSON-RPC ID, the ID validation fails with a confusing
parsing error. This adds the actual response error message to the
log output, making the root cause immediately visible.
@codecov

codecov Bot commented Jan 20, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 8 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
protocol/chainlib/jsonRPC.go 0.00% 4 Missing ⚠️
protocol/chainlib/tendermintRPC.go 0.00% 4 Missing ⚠️
Flag Coverage Δ
consensus 8.53% <ø> (?)
protocol 33.75% <0.00%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
protocol/chainlib/jsonRPC.go 43.91% <0.00%> (ø)
protocol/chainlib/tendermintRPC.go 39.40% <0.00%> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@nimrod-teich nimrod-teich merged commit 9d5b671 into main Jan 20, 2026
29 checks passed
@nimrod-teich nimrod-teich deleted the fix/better_observe_error branch January 20, 2026 10:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants