eip-712-ballots - #1733
Merged
Merged
eip-712-ballots#1733
Conversation
|
🚅 Deployed to the app-pr-1733 environment in Drips App
|
railway-app
Bot
temporarily deployed
to
App (Drips App / app-pr-1733)
November 12, 2025 15:13
Destroyed
railway-app
Bot
temporarily deployed
to
Drips Optimism App (Drips App / staging)
November 12, 2025 15:15
Inactive
railway-app
Bot
temporarily deployed
to
Drips Sepolia App (Drips App / staging)
November 12, 2025 15:15
Inactive
railway-app
Bot
temporarily deployed
to
Drips Mainnet App (Drips App / staging)
November 12, 2025 15:15
Inactive
railway-app
Bot
temporarily deployed
to
Drips Metis App (Drips App / staging)
November 12, 2025 15:15
Inactive
railway-app
Bot
temporarily deployed
to
Drips Filecoin App (Drips App / staging)
November 12, 2025 15:15
Inactive
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR introduces EIP-712 wallet signature verification for RPGF ballot submissions to ensure ballot authenticity. The implementation adds cryptographic signing to the ballot submission flow and updates the UI to clearly communicate wallet confirmation steps to users.
- Adds a new
signBallotutility that creates EIP-712 typed data from ballots and prompts users to sign with their wallet - Refactors ballot submission flows (JSON and spreadsheet-based) to require signatures and chainId
- Updates UI components to use wallet icons and messaging that clearly indicates wallet confirmation is required
Reviewed Changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| src/lib/utils/rpgf/types/ballot.ts | Adds signature and chainId fields to SubmitBallotDto type |
| src/lib/utils/rpgf/sign-ballot.ts | New utility for creating deterministic ballot hashes and generating EIP-712 signatures |
| src/lib/utils/rpgf/rpgf.ts | Integrates signature signing into all ballot submission paths (JSON, CSV, XLSX) and refactors spreadsheet submission logic |
| src/lib/flows/submit-rpgf-ballot/steps/confirm.svelte | Updates confirmation step with wallet icon, wallet-focused messaging, and annotation box explaining signature request |
| src/lib/flows/rpgf-spreadsheet-vote-flow/upload-ballot.svelte | Updates spreadsheet upload UI with wallet icon and wallet confirmation messaging |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
railway-app
Bot
temporarily deployed
to
App (Drips App / app-pr-1733)
November 12, 2025 15:21
Destroyed
railway-app
Bot
temporarily deployed
to
Drips Metis App (Drips App / staging)
November 12, 2025 15:21
Inactive
railway-app
Bot
temporarily deployed
to
Drips Optimism App (Drips App / staging)
November 12, 2025 15:21
Inactive
railway-app
Bot
temporarily deployed
to
Drips Mainnet App (Drips App / staging)
November 12, 2025 15:21
Inactive
railway-app
Bot
temporarily deployed
to
Drips Sepolia App (Drips App / staging)
November 12, 2025 15:21
Inactive
railway-app
Bot
temporarily deployed
to
Drips Filecoin App (Drips App / staging)
November 12, 2025 15:21
Inactive
efstajas
marked this pull request as ready for review
November 12, 2025 15:33
mhgbrown
pushed a commit
that referenced
this pull request
Nov 13, 2025
* eip-712-ballots * allow re-submitting existing ballot without changes by holding down shift
mhgbrown
pushed a commit
that referenced
this pull request
Nov 25, 2025
* eip-712-ballots * allow re-submitting existing ballot without changes by holding down shift
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces a wallet-based signature flow for RPGF ballot submission, ensuring that ballots are cryptographically signed by the user's connected wallet before being submitted. The changes update both the user interface and backend logic to require and handle wallet signatures, and provide more explicit feedback to users about wallet confirmation steps.
Key changes include:
Wallet Signature Integration
signBallotutility (sign-ballot.ts) that generates a deterministic hash of the ballot, creates EIP-712 typed data, and prompts the user's wallet to sign the ballot before submission. The resulting signature and chainId are now included in all ballot submission payloads. [1] [2] [3] [4] [5]SubmitBallotDtotype to includesignatureandchainIdfields, and refactored ballot submission functions (castBallot,castBallotAsCsv,castBallotAsXlsx) to require and transmit these fields. [1] [2]User Interface Updates
AnnotationBoxto the confirmation step, informing users that a wallet signature request will be triggered and reminding them to review their ballot before confirming.Backend API and Ballot Parsing Refactor
These changes collectively enforce ballot authenticity via wallet signatures, improve user communication about wallet interactions, and streamline the ballot submission process.