-
Notifications
You must be signed in to change notification settings - Fork 54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(hub-genesis): whitelisted address trigger genesis transfer #625
Conversation
return err | ||
} | ||
|
||
if !ack.Success() { | ||
w.logger(ctx).Error("acknowledgement failed for genesis transfer", "packet", packet, "ack", ack) | ||
return errors.New("acknowledgement failed for genesis transfer") | ||
// something wrong - need to fix the hub with gov prop and try to send transfer again |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why u removed the logging?
x/hub-genesis/keeper/msg_server.go
Outdated
if !state.CanonicalHubTransferChannelHasBeenSet() { | ||
state.SetCanonicalTransferChannel(port, channelID) | ||
} | ||
if state.HubPortAndChannel.Channel != channelID { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lets assume a bug in relayer and sent wrong channel id with the hub.
in that case after first attempt we're gonna set it (SetCanonicalTransferChannel
).
Than we find out it's acutally a different channel which is the canonical on the hub.
Than we try again, but fail with channel id mismatch
.
Why dot we not simply try every time with the passed channel given we're not in flight (vs setting the first channel attempt as the only one)? ( we will need to clear the canonical transfser channel on ack err though)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice work! small comment/question
goes with dymensionxyz/dymension#1637
Description
Closes #624
All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow-up issues.
PR review checkboxes:
I have...
Unreleased
section inCHANGELOG.md
godoc
commentsSDK Checklist
map
time.Now()
sendCoin
and notSendCoins
Full security checklist here
For Reviewer:
After reviewer approval: