Skip to content
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

Fix Community Pool Calculation #300

Merged
merged 4 commits into from
Feb 10, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ RUN apk add --no-cache \
ca-certificates=20241121-r1 \
libstdc++~=13.2 \
jq~=1.7 \
curl~=8.11 \
curl~=8.12 \
bash~=5.2 \
&& addgroup -g 1000 exocore \
&& adduser -S -h /home/exocore -D exocore -u 1000 -G exocore
Expand Down
2 changes: 1 addition & 1 deletion networks/local/exocore/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ RUN LEDGER_ENABLED=false make build
FROM alpine:3.19 AS run
RUN apk add --no-cache libstdc++~=13.2 \
bash~=5.2 \
curl~=8.11 \
curl~=8.12 \
jq~=1.7 \
&& addgroup -g 1000 exocore \
&& adduser -S -h /home/exocore -D exocore -u 1000 -G exocore
Expand Down
4 changes: 2 additions & 2 deletions x/feedistribution/keeper/allocation.go
Original file line number Diff line number Diff line change
Expand Up @@ -158,8 +158,8 @@ func (k Keeper) AllocateTokensToStakers(ctx sdk.Context, operatorAddress sdk.Acc
remaining = remaining.Sub(rewardToSingleStaker)
}
}
feePool.CommunityPool = feePool.CommunityPool.Add(rewardToAllStakers...)
logger.Info("allocate tokens to stakers successfully", "allocated amount is", rewardToAllStakers.String())
feePool.CommunityPool = feePool.CommunityPool.Add(remaining...)
logger.Info("allocate tokens to stakers successfully", "allocated amount is", rewardToAllStakers.Sub(remaining).String())
}

func (k Keeper) AllocateTokensToSingleStaker(ctx sdk.Context, stakerAddress string, reward sdk.DecCoins) {
Expand Down
Loading