Closed josediegorobles closed 11 months ago
Thank you for filing this, I've been experiencing the same issues.
The problem occurs because the PSBT was created with wrong way (Please, see PR #366 ).
Also, ExploraBlockchain::broadcast
method is badly to troubleshooting transaction error, because the method does not display the problem that caused the badrequest
:.
/// Broadcast a [`Transaction`] to Esplora
pub async fn broadcast(&self, transaction: &Transaction) -> Result<(), Error> {
self.client
.post(&format!("{}/tx", self.url))
.body(serialize(transaction).to_hex())
.send()
.await?
.error_for_status()?;
Ok(())
}
I suggest changing this issue to "replace Esplora::broadcast with direct request"
When the error reported here: https://github.com/diba-io/bitmask-core/issues/364 and maybe in other occasions, all process are done but the transaction is not sent to the blockchain.
So, we need: