Skip to content

Store packets

Store packets #242

Triggered via pull request October 30, 2023 19:58
@dhruvjadhruvja
synchronize #64
store-packets
Status Failure
Total duration 9m 43s
Artifacts
This run and associated checks have been archived and are scheduled for deletion. Learn more about checks retention

master.yml

on: pull_request
Fit to window
Zoom out
Zoom in

Annotations

2 errors and 1 warning
you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`: solana/solana-ibc/programs/solana-ibc/src/lib.rs#L72
error: you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let` --> solana/solana-ibc/programs/solana-ibc/src/lib.rs:72:17 | 72 | / match msg { 73 | | MsgEnvelope::Packet(packet) => { 74 | | // store the packet if not exists 75 | | let mut inner_store = store.0.borrow_mut(); ... | 90 | | _ => (), 91 | | } | |_________________^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match = note: `-D clippy::single-match` implied by `-D warnings` = help: to override `-D warnings` add `#[allow(clippy::single_match)]` help: try | 72 ~ if let MsgEnvelope::Packet(packet) = msg { 73 + // store the packet if not exists 74 + let mut inner_store = store.0.borrow_mut(); 75 + let serialized_packet = borsh::to_vec(&packet).unwrap(); 76 + // Find if the packet already exists 77 + match inner_store 78 + .packets 79 + .0 80 + .iter() 81 + .find(|&pack| pack == &serialized_packet) 82 + { 83 + Some(_) => (), 84 + None => { 85 + inner_store.packets.0.push(serialized_packet) 86 + } 87 + } 88 + } |
Miscellaneous checks
Clippy had exited with the 101 exit code
Miscellaneous checks
The following actions uses node12 which is deprecated and will be forced to run on node16: actions-rs/clippy-check@v1. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/