Increased gas unit number for deployment#337
Conversation
WalkthroughThe static gas unit value used to estimate wallet deployment costs in the code has been increased from 271,000 to 330,000 units. This adjustment affects the calculation of the total gas cost returned by the relevant function, but no other logic or control flow has been changed. Changes
Suggested reviewers
Poem
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 ESLint
npm error Exit handler never called! ✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Actionable comments posted: 0
🧹 Nitpick comments (1)
src/hooks/useDeployWallet.tsx (1)
185-185: Avoid magic number – extractgasUnitsinto a shared constant or config.The new value
BigInt(330000)is hard-coded, making future tuning error-prone and hiding domain knowledge.
Suggest moving it to e.g.const DEFAULT_WALLET_DEPLOY_GAS_UNITS = 330_000n;at module scope (or a centralconstants.ts) and referencing it here.
This keeps the implementation self-documenting and allows unit tests to verify it in one place.- const gasUnits = BigInt(330000); + const gasUnits = DEFAULT_WALLET_DEPLOY_GAS_UNITS;
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
src/apps/pillarx-app/components/MediaGridCollection/tests/__snapshots__/DisplayCollectionImage.test.tsx.snapis excluded by!**/*.snap
📒 Files selected for processing (1)
src/hooks/useDeployWallet.tsx(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (3)
- GitHub Check: lint
- GitHub Check: unit-tests
- GitHub Check: build
Deploying x with
|
| Latest commit: |
4c43e76
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://8554d9dc.x-e62.pages.dev |
| Branch Preview URL: | https://fix-pro-3405-exchange-max-va.x-e62.pages.dev |
Description
How Has This Been Tested?
Screenshots (if appropriate):
Types of changes
Summary by CodeRabbit