-
Notifications
You must be signed in to change notification settings - Fork 49
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
feat: claim rewards #552
feat: claim rewards #552
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
let publisher_exposure = { | ||
let mut publisher_exposure = 0; | ||
for i in 0..positions.get_position_capacity() { | ||
if let Some(position) = positions.read_position(i).unwrap() { | ||
if (position.target_with_parameters | ||
== TargetWithParameters::IntegrityPool { | ||
publisher: *publisher, | ||
}) | ||
{ | ||
publisher_exposure += position.amount; | ||
} | ||
} | ||
} |
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.
this can cause issues if someone unstake but don't claim rewards
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.
they can't clean up their positions until they claim everything
Introducing parallelism created a bunch of issues with running the code in debug mode (stack overflow, segfault) so now we need
cargo run --release
. I haven't been able to solve this.