This repository was archived by the owner on Feb 5, 2026. It is now read-only.
feat(permitter): Add minTokensPerBidder, remove maxBid from Permit struct#5
Merged
jemilezzet merged 8 commits intomainfrom Jan 13, 2026
Conversation
There was a problem hiding this comment.
Pull request overview
This PR introduces a minimum bid requirement (minTokensPerBidder) to the Permitter system and removes the per-permit maxBidAmount field, simplifying the bid validation logic to rely solely on the global maxTokensPerBidder cap.
Changes:
- Added
minTokensPerBidderparameter to enforce a minimum bid amount per transaction - Removed
maxBidAmountfrom thePermitstruct, streamlining to only includebidderandexpiry - Updated EIP-712 typehash to reflect the simplified Permit structure
Reviewed changes
Copilot reviewed 12 out of 13 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/Permitter.sol | Adds minTokensPerBidder validation, removes maxBidAmount from Permit struct, simplifies personal cap checking |
| src/interfaces/IPermitter.sol | Adds BidBelowMinimum and MinTokensExceedsMaxTokens errors, removes maxBidAmount from Permit struct, adds minTokensPerBidder getter |
| src/PermitterFactory.sol | Adds minTokensPerBidder parameter to factory methods and events |
| src/interfaces/IPermitterFactory.sol | Adds minTokensPerBidder to factory interface and events |
| test/Permitter.t.sol | Updates all test signatures to remove maxBidAmount, adds comprehensive tests for minimum bid enforcement |
| test/PermitterFactory.t.sol | Updates all factory calls to include minTokensPerBidder parameter |
| test/Integration.t.sol | Updates integration tests to use simplified permit signatures |
| test/Fuzz.t.sol | Updates fuzz tests with minimum bid constraints and simplified signatures |
| test/ExploitTests.t.sol | Updates exploit tests to use new permit structure |
| .mcp.json | Adds MCP server configuration |
| .gitmodules | Adds Claude commands submodule |
| .claude/commands | Adds Claude commands submodule reference |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Coverage after merging jemil/tally-9985-add-mintokensperbidder-constructor-parameter-and-remove into main will be
Coverage Report
|
|||||||||||||||||||||||||
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
No description provided.