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

[Bug]: x/feegrant: allowance expiration queue is not being cleared during allowance revoking. #20057

Open
1 task done
swelf19 opened this issue Apr 16, 2024 · 0 comments
Open
1 task done
Labels

Comments

@swelf19
Copy link
Contributor

swelf19 commented Apr 16, 2024

Is there an existing issue for this?

  • I have searched the existing issues

What happened?

A bug happened!
When you revoke an allowance in order to create a new one with a later expiration time. The queue entity for the allowance still exists in the expiration queue. Which leads to situation whec the allowance removed unexpectedly due to outdated queue entity in the endblocker.
The bug in not reproducible with sdk.0.50, because queue entity is cleared as well during revoke method.
It's possible to fix it the same way in sdk0.47

Cosmos SDK Version

0.47

How to reproduce?

grant allowance with expiration date = date1
revoke allowance
grant allowance for the same granter + grantee with expiration date = date2
check that expiration queue contains two records

@swelf19 swelf19 added the T:Bug label Apr 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: 📋 Backlog
Development

No branches or pull requests

1 participant