Conversation
WalkthroughA new network entry "morph" is added to the configuration with metaRouter and gateway addresses, and a corresponding SymbiosisFacet deployment is introduced for the morph network in its deployment manifest. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Possibly related PRs
Suggested labels
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@deployments/morph.json`:
- Line 26: Add a Facets entry for SymbiosisFacet to the diamond deployment JSON
so the two public functions become callable: insert an object into the "Facets"
array with "name": "SymbiosisFacet", "address":
"0xCDA650d97F35928f740544E9854f03a1e1c2b81E" (taken from morph.json) and a
"functionSelectors" array that includes the selectors for
startBridgeTokensViaSymbiosis and swapAndStartBridgeTokensViaSymbiosis; ensure
the selector hexes match the SymbiosisFacet ABI and follow the same facet object
structure as the other entries in morph.diamond.json so the diamond knows to
route those calls to SymbiosisFacet.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: fa37ec0f-f252-4f90-82c6-8612be049a05
📒 Files selected for processing (2)
config/symbiosis.jsondeployments/morph.json
| "RelayFacet": "0x830DAfBCAE31141f1f1BfDF96D6Ad545D4cc9bB4", | ||
| "RelayDepositoryFacet": "0xcFDe3d0c9d2Ced6cC5731439Ac8944De0E029Ce4" | ||
| "RelayDepositoryFacet": "0xcFDe3d0c9d2Ced6cC5731439Ac8944De0E029Ce4", | ||
| "SymbiosisFacet": "0xCDA650d97F35928f740544E9854f03a1e1c2b81E" |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -euo pipefail
fd 'morph(\.diamond)?\.json$' deployments -x sh -c '
file="$1"
echo "== $file =="
rg -n -C2 "\"SymbiosisFacet\"|\"LiFiDiamond\"" "$file" || true
' sh {}Repository: lifinance/contracts
Length of output: 784
🏁 Script executed:
cat deployments/morph.diamond.jsonRepository: lifinance/contracts
Length of output: 2654
🏁 Script executed:
fd 'SymbiosisFacet.sol' src/Facets -x cat -n {}Repository: lifinance/contracts
Length of output: 6469
🏁 Script executed:
git diff HEAD~1 HEAD -- deployments/morph.diamond.json | head -50Repository: lifinance/contracts
Length of output: 91
🏁 Script executed:
git diff --name-only 2>/dev/null | grep deployments || echo "Cannot determine git diff context"Repository: lifinance/contracts
Length of output: 96
Register SymbiosisFacet in deployments/morph.diamond.json as part of this PR.
Line 26 in deployments/morph.json records the deployed implementation address for SymbiosisFacet. However, SymbiosisFacet is missing from the Facets array in deployments/morph.diamond.json. Without diamond registration, the public functions startBridgeTokensViaSymbiosis and swapAndStartBridgeTokensViaSymbiosis will remain unreachable through LiFiDiamond on Morph, making the deployment incomplete.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@deployments/morph.json` at line 26, Add a Facets entry for SymbiosisFacet to
the diamond deployment JSON so the two public functions become callable: insert
an object into the "Facets" array with "name": "SymbiosisFacet", "address":
"0xCDA650d97F35928f740544E9854f03a1e1c2b81E" (taken from morph.json) and a
"functionSelectors" array that includes the selectors for
startBridgeTokensViaSymbiosis and swapAndStartBridgeTokensViaSymbiosis; ensure
the selector hexes match the SymbiosisFacet ABI and follow the same facet object
structure as the other entries in morph.diamond.json so the diamond knows to
route those calls to SymbiosisFacet.
Which Jira task belongs to this PR?
Why did I implement it this way?
Checklist before requesting a review
Checklist for reviewer (DO NOT DEPLOY and contracts BEFORE CHECKING THIS!!!)