fix: avoid adding MsgOracleRealyTypeUrl before config enabled#126
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review infoConfiguration used: Organization UI Review profile: CHILL Plan: Pro Cache: Disabled due to data retention organization setting Knowledge base: Disabled due to 📒 Files selected for processing (1)
WalkthroughThe change gates oracle-relay authz grant creation and the set of required message types behind Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Poem
🚥 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)
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 `@cmd/opinitd/tx.go`:
- Around line 118-121: The current requiredMsgTypes initialization incorrectly
always includes types.MsgRelayOracleTypeUrl and omits
types.MsgUpdateOracleTypeUrl when cfg.OracleRelay.Enable is false; update the
logic in the requiredMsgTypes construction (the requiredMsgTypes variable) to
start from a base slice of always-required types (e.g., include
types.MsgAuthzExecTypeUrl and types.MsgUpdateOracleTypeUrl) and only append
relay-related types (types.MsgRelayOracleTypeUrl and
types.MsgUpdateClientTypeUrl) when cfg.OracleRelay.Enable is true so that relay
message types are only added when the feature flag is enabled.
ℹ️ Review info
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Cache: Disabled due to data retention organization setting
Knowledge base: Disabled due to Reviews -> Disable Knowledge Base setting
📒 Files selected for processing (1)
cmd/opinitd/tx.go
Summary by CodeRabbit