-
Notifications
You must be signed in to change notification settings - Fork 122
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
lint legacy ibc testing #1078
lint legacy ibc testing #1078
Conversation
legacy_ibc_testing/core/events.go
Outdated
@@ -36,7 +36,7 @@ func ReconstructPacketFromEvent(event abci.Event) (packet types.Packet, err erro | |||
return packet, err | |||
} | |||
return types.NewPacket( | |||
attrMap[string(types.AttributeKeyData)], // data | |||
attrMap[string(types.AttributeKeyDataHex)], // data |
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.
What does this change do? Doesn't seem like a lint
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.
old call is deprecated and I think that these both return the same thing
legacy_ibc_testing/testing/events.go
Outdated
@@ -69,7 +69,7 @@ func ParseAckFromEvents(events sdk.Events) ([]byte, error) { | |||
for _, ev := range events { | |||
if ev.Type == channeltypes.EventTypeWriteAck { | |||
for _, attr := range ev.Attributes { | |||
if string(attr.Key) == channeltypes.AttributeKeyAck { | |||
if attr.Key == channeltypes.AttributeKeyAckHex { |
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.
Same question as above. Maybe the two changes are tied together but I'm evaluating this as a linting / fully refactor PR
These changes seem to make tests fail |
ah, you know, that explains some stuff. Also, it is in the exact location you flagged -- I thought the two calls did the same thing. Thanks! |
PS: do you know where to find the preview tab? |
@faddat When you open a PR using the github UI (https://github.com/cosmos/interchain-security/compare), you have a |
Thanks @mpoke -- is it posssible to settle on one template? I'll fix this one up manually, but basically here's my usual workflow, which is why you're still sometimes seeing this from me: git checkout origin/main
git switch -c faddat/branchname
# do stuff
git commit -a
gh pr create --draft
# do more stuff
git commit -a
gh pr ready 1078 |
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.
LGTM
Having different templates for different contributions types helps with the workflow. For example, a bug fix has different requirements than an update of the docs.
I'm not that familiar with the |
@faddat please run make lint or make format so the golangci-lint test can pass. Then this is ready to merge, thanks |
awesome, just a moment sir. |
I apologize, because
gh
has no such preview tab.This PR lints the legacy_ibc_testing folder.
Please go the the
Preview
tab and select the appropriate sub-template:fix
,feat
, andrefactor
.