Skip to content

Pectra touch-ups #744

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

Merged
merged 50 commits into from
May 5, 2025
Merged

Pectra touch-ups #744

merged 50 commits into from
May 5, 2025

Conversation

wackerow
Copy link
Member

@wackerow wackerow commented Mar 3, 2025

Preview: https://deploy-preview-744--phenomenal-frangipane-7c4bd1.netlify.app/en/validator-actions

  • Adds check for 256 epochs past activation before actions that involve transferring funds out of a validator (consolidation source, full exit, or partial withdrawals)
  • Adds supporting copy to explain that to user; action buttons disabled if criteria not met
  • Adds gas calculation for adding funds to account for tx fee (ie, if user has exactly 1 ETH, cannot actually send that full 1 ETH)
  • Updated REACT_APP_BEACONCHAIN_URL and REACT_APP_EL_EXPLORER_URL to new URLs
  • Added a new explanatory text about the execution layer confirmation.
  • Added several new messages related to validator status, account upgrades, and transaction confirmations. Removed some outdated messages.

This comment was marked as outdated.

Copy link

netlify bot commented Mar 27, 2025

Deploy Preview for phenomenal-frangipane-7c4bd1 ready!

Name Link
🔨 Latest commit 48d40e7
🔍 Latest deploy log https://app.netlify.com/sites/phenomenal-frangipane-7c4bd1/deploys/6818f8439d52c80008db1d93
😎 Deploy Preview https://deploy-preview-744--phenomenal-frangipane-7c4bd1.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

temporary while dev env vars are being updated
accounts activated less than 256 epochs ago are ineligible to transfer funds out via partial withdrawals or as the source account in a consolidation due to possible sync committee conflict
Endpoint no longer supporting testnets; Beaconcha.in link remains visible.
Use beaconcha.in and etherscan.io
@wackerow wackerow force-pushed the pectra-post-holesky branch from d7ed665 to 2bc7d28 Compare April 14, 2025 03:18
@wackerow wackerow marked this pull request as ready for review April 16, 2025 15:52
remyroy and others added 21 commits April 30, 2025 12:02
Better handling for validator details API response in top ups
use guard clause for confirmation string validation; return false if target not yet selected, true if credentials already match, else check string
replace redundant mention of max available
@wackerow wackerow requested a review from Copilot May 5, 2025 17:37
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This pull request adds multiple improvements to the validator UI and underlying transaction logic for upgrading, consolidating, and withdrawing funds. Key changes include new UI states for validator statuses, integration of 256‐epoch checks before certain actions, improved gas fee calculations on deposit, updates to environment variable URLs, and refined messaging throughout the application.

Reviewed Changes

Copilot reviewed 22 out of 25 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/pages/TopUp/components/ValidatorTable.tsx Adds new cases for various validator status displays.
src/pages/ConnectWallet/Chains.ts Inserts a blank line; ensure the environment variable naming is consistent.
src/pages/Actions/utils.ts Updates fee calculation using integer division for accurate fee rounding.
src/pages/Actions/index.tsx Updates messaging and introduces a deposits URL using new Link component.
src/pages/Actions/components/ValidatorSelector.tsx Introduces optional search and auto-selection logic for validator selection.
src/pages/Actions/components/ValidatorDetails.tsx Adjusts formatting (e.g. fixed decimals, updated beacon explorer link).
src/pages/Actions/components/ValidatorActions.tsx Updates messaging for fund withdrawal and consolidates various action flows.
src/pages/Actions/components/UpgradeCompounding.tsx Revises messaging and adds further explanatory text with updated styling.
src/pages/Actions/components/PushConsolidation.tsx Introduces additional validation for target validator status and confirmation logic.
src/pages/Actions/components/PartialWithdraw.tsx Adds minimum value support and adjusts withdrawal UI text and formatting.
src/pages/Actions/components/ForceExit.tsx Renames actions and updates messages in the exit flow.
src/pages/Actions/components/AddFunds.tsx Updates fee estimation logic, balance calculations, and adjusts inline styling.
src/components/TransactionStatusModal/TransactionProgress.tsx Updates messaging to reflect confirmation on the execution layer.
src/components/Select.tsx Adds an optional search callback to the select component.
Files not reviewed (3)
  • .env.hoodi: Language not supported
  • src/intl/compiled/en.json: Language not supported
  • src/intl/en.json: Language not supported
Comments suppressed due to low confidence (3)

src/pages/Actions/components/ValidatorActions.tsx:187

  • [nitpick] The default message uses 'withdrawal' as a verb. Consider replacing it with 'withdraw' for grammatical correctness.
<FormattedMessage defaultMessage="{subject} can withdrawal any portion of staked {TICKER_NAME} over {MIN_ACTIVATION_BALANCE}." />

src/pages/ConnectWallet/Chains.ts:1

  • The environment variable 'EL_EXPLOER_URL' appears to be misspelled; ensure consistent naming (perhaps 'EL_EXPLORER_URL') across the codebase.
import { EL_EXPLOER_URL, RPC_URL, NETWORK_NAME } from '../../utils/envVars';

src/pages/Actions/components/AddFunds.tsx:344

  • [nitpick] Repeated inline style definitions in modal components are used in several files. Consider extracting these common styles into shared styled components for improved maintainability.
style={{ textAlign: 'end', fontFamily: 'monospace' }}

Copy link
Contributor

@CarlBeek CarlBeek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This really ended up becoming the Pectra feature fork, thanks for all the work @wackerow @valefar-on-discord & @remyroy!

@CarlBeek CarlBeek merged commit c30c1cc into dev May 5, 2025
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants