Skip to content
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

Update send packet/transfer #468

Merged
merged 17 commits into from
Feb 24, 2023
Merged

Update send packet/transfer #468

merged 17 commits into from
Feb 24, 2023

Conversation

plafer
Copy link
Contributor

@plafer plafer commented Feb 24, 2023

Closes: #442

  • Separates send_{packet,transfer}() into *_validation() and *_execution()
  • Removes old ModuleOutput/ModuleOutputBuilder structs
  • Removes unused callback methods in Module

PR author checklist:

  • Added changelog entry, using unclog.
  • Added tests.
  • Linked to GitHub issue.
  • Updated code comments and documentation (e.g., docs/).
  • Tagged one reviewer who will be the one responsible for shepherding this PR.

Reviewer checklist:

  • Reviewed Files changed in the GitHub PR explorer.
  • Manually tested (in case integration/unit/mock tests are absent).

@codecov
Copy link

codecov bot commented Feb 24, 2023

Codecov Report

Base: 69.54% // Head: 71.30% // Increases project coverage by +1.76% 🎉

Coverage data is based on head (2f1fce1) compared to base (9713ec8).
Patch coverage: 89.51% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #468      +/-   ##
==========================================
+ Coverage   69.54%   71.30%   +1.76%     
==========================================
  Files         126      126              
  Lines       16228    15935     -293     
==========================================
+ Hits        11285    11363      +78     
+ Misses       4943     4572     -371     
Impacted Files Coverage Δ
crates/ibc/src/applications/transfer/relay.rs 0.00% <0.00%> (ø)
.../src/applications/transfer/relay/on_recv_packet.rs 0.00% <0.00%> (ø)
crates/ibc/src/core/handler.rs 78.26% <ø> (ø)
crates/ibc/src/core/ics26_routing/context.rs 82.14% <ø> (+29.06%) ⬆️
crates/ibc/src/applications/transfer/context.rs 51.74% <51.85%> (+16.77%) ⬆️
.../ibc/src/core/ics04_channel/handler/send_packet.rs 81.63% <94.28%> (+3.22%) ⬆️
crates/ibc/src/test_utils.rs 79.66% <95.77%> (+12.15%) ⬆️
...c/src/applications/transfer/relay/send_transfer.rs 96.02% <96.59%> (+0.28%) ⬆️
crates/ibc/src/core/context.rs 84.34% <100.00%> (ø)
crates/ibc/src/core/context/acknowledgement.rs 97.32% <100.00%> (ø)
... and 13 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@plafer plafer marked this pull request as ready for review February 24, 2023 15:10
Copy link
Member

@Farhad-Shabani Farhad-Shabani left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👌

@Farhad-Shabani Farhad-Shabani added the A: breaking Admin: breaking change that may impact operators label Feb 24, 2023
}

pub fn process_recv_packet_execute<Ctx: TokenTransferContext>(
pub fn process_recv_packet_execute<Ctx: TokenTransferExecutionContext>(
ctx: &mut Ctx,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ctx or ctx_b

@plafer plafer merged commit c13ca35 into main Feb 24, 2023
@plafer plafer deleted the plafer/442-send-packet-transfer branch February 24, 2023 19:18
Farhad-Shabani pushed a commit that referenced this pull request Sep 9, 2024
* send_packet_validate()

* send_packet_execute

* send_transfer_validate

* fmt

* send_transfer_validate: call send_packet_validate

* send_transfer_execute

* SendPacketValidationContext

* send_packet_validate uses SendPacketValidationContext

* SendPacketExecutionContext

* TokenTransferExecutionContext

* cleanup

* remove unused recv_packet

* Remove `ModuleOutput`

* Remove unused `Module` callbacks

* changelog

* use CommitmentPath ctor

* add back send_transfer comment
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A: breaking Admin: breaking change that may impact operators
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Adapt send_packet() and send_transfer() API
2 participants