refactor: deploy self-collateralized markets without the EdgeFactory - #4
Merged
Merged
Conversation
The EdgeFactory is deprecated: its address is removed from the euler-interfaces address book and the edgeFactory field is dropped from the PeripheryAddresses struct in evk-periphery, so the script would read address(0) today and stop compiling on the next submodule bump. Instead of depending on the on-chain factory, replicate its deployment flow directly: deploy the router via the (kept) oracle router factory, reuse or create the escrowed collateral singleton vault via the (kept) escrowed collateral perspective, deploy the borrowable vault, configure LTV and renounce governance - identical parameters and ordering to EdgeFactory.deploy for the two-vault case.
kasperpawlowski
marked this pull request as ready for review
August 10, 2026 14:56
Seranged
approved these changes
Aug 10, 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.
Summary
The EdgeFactory is deprecated: euler-xyz/euler-interfaces#226 removes its address from the address book, and euler-xyz/evk-periphery#430 drops the
edgeFactoryfield from thePeripheryAddressesstruct.For this repo that means: a submodule bump alone is not sufficient — today (pinned submodule) the script still compiles but
peripheryAddresses.edgeFactorydeserializes toaddress(0)once the address book PR merges, and after a bump it stops compiling because the struct field is gone.Rather than depending on the deprecated on-chain factory at all, this replicates its deployment flow inline for the two-vault self-collateralization case, using only contracts that stay in the address book:
oracleRouterFactory, governed by the deployerescrowedCollateralPerspective.singletonLookup, or deploy + verify it (same as EdgeFactory)Parameters and ordering mirror
EdgeFactory.deployexactly.Test plan
forge buildclean--dry-runagainst a fork before next use