-
Notifications
You must be signed in to change notification settings - Fork 118
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add logging and validation improvements #589
Conversation
d4476db
to
82adb09
Compare
Codecov ReportAttention: Patch coverage is
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## main #589 +/- ##
==========================================
- Coverage 30.44% 30.41% -0.03%
==========================================
Files 41 41
Lines 6268 6273 +5
==========================================
Hits 1908 1908
- Misses 4113 4118 +5
Partials 247 247
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm. left a small comment and not sure why changing uint to int?
Co-authored-by: Chris Hager <chris@linuxuser.at>
postgres bigint uses int64, and the error occurs when user input larger than int64 is entered. Changing from uint64 to int64 would bound the values to int64, the same representation as Postgres and the error will be handled in |
📝 Summary
Some logging improvements and validation:
failed getting execution payload (2/2) - payload not found, but found bid in database
- this error log occurred often due to race conditions in which a submission passedcheckFloorBidValue
earlier in the request and was simulated. However a higher value bid was simulated and updated in redis before the block submission finished simulation, resulting in a bid below the floor whenSaveBidAndUpdateTopBid
is reached. The bid is saved but the payload was not.bigint
in postgres is represented as a int64 value which was not properly validated in the request parameters and uint64 values could be inputted.⛱ Motivation and Context
Reduces error logging noise in the relay.
📚 References
✅ I have run these commands
make lint
make test-race
go mod tidy
CONTRIBUTING.md