Skip to content

Commit

Permalink
Add TODO comment to SealevelProvider
Browse files Browse the repository at this point in the history
  • Loading branch information
ameten committed Oct 30, 2024
1 parent 3dbdb51 commit 0c396eb
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions rust/main/chains/hyperlane-sealevel/src/provider.rs
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,12 @@ impl HyperlaneProvider for SealevelProvider {
Ok(block_info)
}

/// TODO This method is superfluous for Solana.
/// Since we have to request full block to find transaction hash and transaction index
/// for Solana, we have all the data about transaction mach earlier before this
/// method is invoked.
/// We can refactor abstractions so that our chain-agnostic code is more suitable
/// for all chains, not only Ethereum-like chains.
async fn get_txn_by_hash(&self, hash: &H512) -> ChainResult<TxnInfo> {
let signature = Signature::new(hash.as_bytes());
let transaction = self.rpc_client.get_transaction(&signature).await?;
Expand Down

0 comments on commit 0c396eb

Please sign in to comment.