mrtnetwork / bitcoin_base

A versatile library for Bitcoin, Dogecoin, Litecoin, Dash, BSV and Bitcoin Cash. Supports P2PK, P2PKH, P2SH, P2WPKH, P2WSH, Taproot, with advanced creation, signing, and spending capabilities.
BSD 3-Clause "New" or "Revised" License
23 stars 19 forks source link

BItcoin transaction #1

Closed ivofernandes closed 11 months ago

ivofernandes commented 11 months ago

I'm trying to use this lib as part of a crypto wallet but got stuck in this error:

  final changeAddr = P2pkhAddress(
    address: 'tb1qhtnl5n66h242e580h9sdkz8edjk335j9mrzyxj',
  );

Seems like tb1qhtnl5n66h242e580h9sdkz8edjk335j9mrzyxj has an l that is not in base58 alphabet

Added the test in this fork https://github.com/ivofernandes/bitcoin_base/blob/main/test/transaction_test.dart

The problem is in the blockchain_utils but at the same time the project is not using the last version of blockchain_utils

Can you help with this?

mrtnetwork commented 11 months ago

I'm trying to use this lib as part of a crypto wallet but got stuck in this error:

  final changeAddr = P2pkhAddress(
    address: 'tb1qhtnl5n66h242e580h9sdkz8edjk335j9mrzyxj',
  );

Seems like tb1qhtnl5n66h242e580h9sdkz8edjk335j9mrzyxj has an l that is not in base58 alphabet

Added the test in this fork https://github.com/ivofernandes/bitcoin_base/blob/main/test/transaction_test.dart

The problem is in the blockchain_utils but at the same time the project is not using the last version of blockchain_utils

Can you help with this?

I update package tomorrow,but tb1qhtnl5n66h242e580h9sdkz8edjk335j9mrzyxj address is p2wsh u must use P2wshAddress

P2wshAddress(address: "tb1qhtnl5n66h242e580h9sdkz8edjk335j9mrzyxj");
mrtnetwork commented 11 months ago

I'm trying to use this lib as part of a crypto wallet but got stuck in this error:

  final changeAddr = P2pkhAddress(
    address: 'tb1qhtnl5n66h242e580h9sdkz8edjk335j9mrzyxj',
  );

Seems like tb1qhtnl5n66h242e580h9sdkz8edjk335j9mrzyxj has an l that is not in base58 alphabet

Added the test in this fork https://github.com/ivofernandes/bitcoin_base/blob/main/test/transaction_test.dart

The problem is in the blockchain_utils but at the same time the project is not using the last version of blockchain_utils

Can you help with this?

I have updated both bitcoin_base, blockchain_utils packages and now you can obtain them from Pub.