feat(vibenet): v3 Validity UI — buy/sell exactly 100 VIBE (exact-in/out) - #149
Merged
Merged
Conversation
Collaborator
✅ Heimdall Review Status
|
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
mbeutt-cb
previously approved these changes
Sep 3, 2026
haardikk21
previously approved these changes
Sep 3, 2026
…ct-in/out helper Targets the fresh v3 0-fee pool and makes both sides trade exactly 100 VIBE: - placeOrder: sell = swapExactIn (put in 100 VIBE, take >= the limit USDV); buy = swapExactOut (take exactly 100 VIBE, spend <= the limit USDV). The helper computes the variable leg on-chain, so neither donates to the pool. - Hardcode the deterministic v3 singleton addresses (factory/helper/minter); ABIs are minimal parseAbi fragments (swapExactIn + swapExactOut), so the client no longer bundles contract deploy bytecode. VIBE + the pair are still discovered from the factory. - Bump the localStorage key (v6 -> v7) so stale orders against the old pool don't linger after the swap. Supersedes the unmerged base/ui v2 PR (#148) — goes straight from the v1 demo to v3 (only vibenet's v2 landed, so main was mismatched). The SwapHelper.json artifact is retained only as input to base/vibenet's bytecode-manifest generator; the client no longer imports it. Pairs with base/vibenet (addresses must match the v3 salt + helper bytecode). Co-Authored-By: Claude <noreply@anthropic.com>
BrianBland
dismissed stale reviews from haardikk21 and mbeutt-cb
via
September 3, 2026 20:11
e4a7ee7
BrianBland
force-pushed
the
brianbland/vibenet-validity-v3-exact-buy-sell
branch
from
September 3, 2026 20:11
7f547ab to
e4a7ee7
Compare
BrianBland
enabled auto-merge
September 3, 2026 20:15
haardikk21
approved these changes
Sep 3, 2026
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.
Companion to base/vibenet#42. Targets the fresh v3 0-fee pool and makes both sides of the demo trade exactly 100 VIBE.
What
placeOrder: sell =swapExactIn(put in 100 VIBE, take ≥ the limit USDV); buy =swapExactOut(take exactly 100 VIBE, spend ≤ the limit USDV, with a 0.1%+1wei cap headroom for rounding). The helper computes the variable leg on-chain, so neither side leaves a surplus in the pool.parseAbifragments (swapExactIn+swapExactOut), so the client no longer bundles contract deploy bytecode. VIBE + the pair are still discovered from the factory.v6 → v7so stale orders against the old pool don't linger after the swap.Heads-up: supersedes #148
Only vibenet's v2 (#39) merged; the v2 UI PR (#148) never did, so
mainwas still the v1 demo (v1 salt, exact-out,predictSingleton) while vibenet moved to v2 — a mismatch. This PR goes straight v1 → v3 and supersedes #148 (please close it). Merge this together with base/vibenet#42.Verified
tsc0,eslint0 errors (pre-existing warnings only), 63/63 validity tests.SwapHelper.jsonis retained only as input to base/vibenet's manifest generator.Pairs with base/vibenet#42 — the hardcoded addresses must match the v3 salt + helper bytecode there.