-
Notifications
You must be signed in to change notification settings - Fork 17
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
1310 modify gasprices storage to support multi asset fees #1412
1310 modify gasprices storage to support multi asset fees #1412
Conversation
🦋 Changeset detectedLatest commit: 30d7049 The changes in this PR will be included in the next version bump. This PR includes changesets to release 10 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
44c356a
to
557677b
Compare
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 seems to properly implement alternative gas prices retrieved from the compact block!
tagging #1413 as relevant follow-up work.
await this.indexedDb.saveGasPrices( | ||
new GasPrices({ | ||
assetId: this.stakingAssetId, | ||
...compactBlock.gasPrices, | ||
}), | ||
); | ||
} | ||
if (compactBlock.altGasPrices.length) { | ||
for (const gasPrice of compactBlock.altGasPrices) { | ||
await this.indexedDb.saveGasPrices(gasPrice); | ||
} |
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.
return ( | ||
umNote.heightSpent === 0n && | ||
!isZero(getAmountFromRecord(umNote)) && | ||
umNote.addressIndex?.equals(addressIndex) |
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.
nice filtering for address index here
asset_id: alt_gas, | ||
block_space_price: gas_prices.block_space_price * 10, | ||
compact_block_space_price: gas_prices.compact_block_space_price * 10, | ||
verification_price: gas_prices.verification_price * 10, | ||
execution_price: gas_prices.execution_price * 10, |
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.
gas fee token price multiplier will instead be determined by governance proposals, rather than arbitrarily setting a 10x multiplier.
Closes #1310
Fixes #1404
Fixes #1397