celestiaorg / celestia-node

Celestia Data Availability Nodes
Apache License 2.0
932 stars 926 forks source link

[Feature Request]: Update Grant Amount in Celestia's FeeGrant Module #3916

Open a26nine opened 2 weeks ago

a26nine commented 2 weeks ago

Implementation ideas

Feature Request: Update Grant Amount in Celestia's FeeGrant Module

Description:

The feeGrant module in celestia-node enables a Granter to cover the transaction fees of a Grantee's blob submission. This is facilitated by granting a fee allowance, which authorizes the Grantee to submit blobs on behalf of the Granter up to a specified threshold.

Problem:

Currently, there's no way to modify the "grant amount" once it's set. Attempting to update it using the same process results in the following error:

failed to execute message; message index: 0: fee allowance already exists: invalid request

This behavior is evident in this transaction, which fails when attempting to increase the allowance for an existing grant.

Proposed Solution:

Implement a feature that allows updating an existing grant amount. This would improve flexibility by eliminating the need to revoke the previous grant and create a new one each time a threshold adjustment is necessary.

Benefits:

jcstein commented 2 weeks ago

I agree that this would be useful. I think this also may need a corresponding issue to be made in https://github.com/celestia-app