-
Notifications
You must be signed in to change notification settings - Fork 434
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
Bids 2369/total withdrawals stats #2581
Conversation
b7fd02a
to
325f579
Compare
325f579
to
2a5ba87
Compare
@@ -783,3 +787,117 @@ func exportHistoricPrices(dayStart uint64, dayEnd uint64) { | |||
|
|||
logrus.Info("historic price update run completed") | |||
} | |||
|
|||
func exportStatsTotals(columns string, dayStart, dayEnd, concurrency uint64) { |
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.
Example Usage:
go run cmd/misc/main.go --config __gitignore/config.yml --command export-stats-totals --columns withdrawals_total,withdrawals_amount_total --day-start 10 --day-end 12
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.
Please have a look at my comments.
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.
Looks good, please just update the error message.
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.
utACK
d7c2964
to
f339a4a
Compare
Splitting this PR into two parts, see #2653 |
See #2668 |
🤖 Generated by Copilot at 2711c31
This pull request adds support for tracking and exporting the cumulative totals of withdrawals for validators in the
validator_stats
table. It introduces a newexport-stats-totals
command to themisc
tool, which populates the new columnswithdrawals_total
andwithdrawals_amount_total
in the table. It also improves the performance and accuracy of theapiValidator
function and thedb
package functions that query the withdrawals totals. It includes a new SQL migration file,temp_add_total_withdrawals_stats.sql
, to add and remove the new columns. It updates theValidatorStatsTableDbRow
type in thetypes
package to match the new table schema.