Skip to content

Commit

Permalink
v4.3.0
Browse files Browse the repository at this point in the history
- Update dependencies.
  • Loading branch information
mrtnetwork committed Jun 15, 2024
1 parent 910cf1e commit 9293ccc
Show file tree
Hide file tree
Showing 39 changed files with 89 additions and 68 deletions.
2 changes: 1 addition & 1 deletion .dart_tool/extension_discovery/vs_code.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"version":2,"entries":[{"package":"xrpl_dart","rootUri":"../","packageUri":"lib/"}]}
{"version":2,"entries":[{"package":"blockchain_utils","rootUri":"../../bitcoin/blockchain_utils/","packageUri":"lib/"},{"package":"xrpl_dart","rootUri":"../","packageUri":"lib/"}]}
9 changes: 6 additions & 3 deletions .dart_tool/package_config.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
},
{
"name": "blockchain_utils",
"rootUri": "file:///Users/macbookpro/.pub-cache/hosted/pub.dev/blockchain_utils-3.0.0",
"rootUri": "file:///Users/macbookpro/.pub-cache/hosted/pub.dev/blockchain_utils-3.1.0",
"packageUri": "lib/",
"languageVersion": "2.15"
},
Expand Down Expand Up @@ -302,7 +302,10 @@
"languageVersion": "2.15"
}
],
"generated": "2024-05-30T05:31:17.826794Z",
"generated": "2024-06-15T18:06:00.485175Z",
"generator": "pub",
"generatorVersion": "3.3.3"
"generatorVersion": "3.4.3",
"flutterRoot": "file:///Users/macbookpro/Documents/flutter",
"flutterVersion": "3.22.2",
"pubCache": "file:///Users/macbookpro/.pub-cache"
}
8 changes: 4 additions & 4 deletions .dart_tool/package_config_subset
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,6 @@ async
2.18
file:///Users/macbookpro/.pub-cache/hosted/pub.dev/async-2.11.0/
file:///Users/macbookpro/.pub-cache/hosted/pub.dev/async-2.11.0/lib/
blockchain_utils
2.15
file:///Users/macbookpro/.pub-cache/hosted/pub.dev/blockchain_utils-3.0.0/
file:///Users/macbookpro/.pub-cache/hosted/pub.dev/blockchain_utils-3.0.0/lib/
boolean_selector
2.17
file:///Users/macbookpro/.pub-cache/hosted/pub.dev/boolean_selector-2.1.1/
Expand Down Expand Up @@ -194,6 +190,10 @@ yaml
2.19
file:///Users/macbookpro/.pub-cache/hosted/pub.dev/yaml-3.1.2/
file:///Users/macbookpro/.pub-cache/hosted/pub.dev/yaml-3.1.2/lib/
blockchain_utils
2.15
file:///Users/macbookpro/Documents/bitcoin/blockchain_utils/
file:///Users/macbookpro/Documents/bitcoin/blockchain_utils/lib/
xrpl_dart
2.15
file:///Users/macbookpro/Documents/xrpl_dart/
Expand Down
Binary file added .dart_tool/pub/bin/test/test.dart-3.4.3.snapshot
Binary file not shown.
Binary file modified .dart_tool/test/incremental_kernel.Ly9AZGFydD0yLjE1
Binary file not shown.
2 changes: 1 addition & 1 deletion .dart_tool/version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.19.5
3.22.2
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 4.3.0

- Update dependencies.

## 4.2.0

- Update dependencies.
Expand Down
34 changes: 17 additions & 17 deletions example/pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,9 @@ packages:
blockchain_utils:
dependency: "direct main"
description:
name: blockchain_utils
sha256: "699d72427447814bd574b95b0d3baf9b2c0ec9c9b82deef3c6264c6f5efa4406"
url: "https://pub.dev"
source: hosted
path: "../../bitcoin/blockchain_utils"
relative: true
source: path
version: "3.0.0"
boolean_selector:
dependency: transitive
Expand Down Expand Up @@ -119,26 +118,26 @@ packages:
dependency: transitive
description:
name: leak_tracker
sha256: "78eb209deea09858f5269f5a5b02be4049535f568c07b275096836f01ea323fa"
sha256: "7f0df31977cb2c0b88585095d168e689669a2cc9b97c309665e3386f3e9d341a"
url: "https://pub.dev"
source: hosted
version: "10.0.0"
version: "10.0.4"
leak_tracker_flutter_testing:
dependency: transitive
description:
name: leak_tracker_flutter_testing
sha256: b46c5e37c19120a8a01918cfaf293547f47269f7cb4b0058f21531c2465d6ef0
sha256: "06e98f569d004c1315b991ded39924b21af84cf14cc94791b8aea337d25b57f8"
url: "https://pub.dev"
source: hosted
version: "2.0.1"
version: "3.0.3"
leak_tracker_testing:
dependency: transitive
description:
name: leak_tracker_testing
sha256: a597f72a664dbd293f3bfc51f9ba69816f84dcd403cdac7066cb3f6003f3ab47
sha256: "6ba465d5d76e67ddf503e1161d1f4a6bc42306f9d66ca1e8f079a47290fb06d3"
url: "https://pub.dev"
source: hosted
version: "2.0.1"
version: "3.0.1"
lints:
dependency: transitive
description:
Expand Down Expand Up @@ -167,10 +166,10 @@ packages:
dependency: transitive
description:
name: meta
sha256: d584fa6707a52763a52446f02cc621b077888fb63b93bbcb1143a7be5a0c0c04
sha256: "7687075e408b093f36e6bbf6c91878cc0d4cd10f409506f7bc996f68220b9136"
url: "https://pub.dev"
source: hosted
version: "1.11.0"
version: "1.12.0"
path:
dependency: transitive
description:
Expand Down Expand Up @@ -228,10 +227,10 @@ packages:
dependency: transitive
description:
name: test_api
sha256: "5c2f730018264d276c20e4f1503fd1308dfbbae39ec8ee63c5236311ac06954b"
sha256: "9955ae474176f7ac8ee4e989dadfb411a58c30415bcfb648fa04b2b8a03afa7f"
url: "https://pub.dev"
source: hosted
version: "0.6.1"
version: "0.7.0"
typed_data:
dependency: transitive
description:
Expand All @@ -252,10 +251,10 @@ packages:
dependency: transitive
description:
name: vm_service
sha256: b3d56ff4341b8f182b96aceb2fa20e3dcb336b9f867bc0eafc0de10f1048e957
sha256: "3923c89304b715fb1eb6423f017651664a03bf5f4b29983627c4da791f74a4ec"
url: "https://pub.dev"
source: hosted
version: "13.0.0"
version: "14.2.1"
web:
dependency: transitive
description:
Expand All @@ -278,6 +277,7 @@ packages:
path: ".."
relative: true
source: path
version: "4.1.2"
version: "4.2.0"
sdks:
dart: ">=3.3.0 <4.0.0"
flutter: ">=3.18.0-18.0.pre.54"
6 changes: 3 additions & 3 deletions example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ dependencies:
http: ^1.1.2
web_socket_channel: ^2.4.0
asn1lib: ^1.5.0
blockchain_utils: ^3.0.0
# blockchain_utils:
# path: ../../bitcoin/blockchain_utils
# blockchain_utils: ^3.0.0
blockchain_utils:
path: ../../bitcoin/blockchain_utils

# The following adds the Cupertino Icons font to your application.
# Use with the CupertinoIcons class for iOS style icons.
Expand Down
7 changes: 4 additions & 3 deletions lib/src/crypto/keypair/xrpl_private_key.dart
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ class XrpSeedUtils {
Base58Decoder.checkDecode(b58String, Base58Alphabets.ripple);

/// Check if the decoded bytes match the provided prefix.
if (!bytesEqual(decoded.sublist(0, prefixLength), prefix)) {
if (!BytesUtils.bytesEqual(decoded.sublist(0, prefixLength), prefix)) {
/// Throw an exception if the prefix does not match, indicating an incorrect prefix.
throw const XRPLAddressCodecException('Provided prefix is incorrect');
}
Expand Down Expand Up @@ -278,9 +278,10 @@ class XRPPrivateKey {
static XRPKeyAlgorithm findAlgorithm(List<int> keyBytes) {
if (keyBytes.length == XrpKeyConst.privateKeyWithPrefix) {
final keyPrefix = keyBytes.sublist(0, 1);
if (bytesEqual(keyPrefix, XrpKeyConst.secpPrivateKey)) {
if (BytesUtils.bytesEqual(keyPrefix, XrpKeyConst.secpPrivateKey)) {
return XRPKeyAlgorithm.secp256k1;
} else if (bytesEqual(keyPrefix, XrpKeyConst.ed255PrivateKeyPrefix)) {
} else if (BytesUtils.bytesEqual(
keyPrefix, XrpKeyConst.ed255PrivateKeyPrefix)) {
return XRPKeyAlgorithm.ed25519;
}
}
Expand Down
4 changes: 2 additions & 2 deletions lib/src/crypto/keypair/xrpl_public_key.dart
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ class XRPPublicKey {
}
if (keyBytes.length == RippleKeyConst.publicKeyLength) {
final prefix = keyBytes.sublist(0, 1);
if (bytesEqual(prefix, Ed25519KeysConst.xrpPubKeyPrefix) ||
bytesEqual(prefix, Ed25519KeysConst.pubKeyPrefix)) {
if (BytesUtils.bytesEqual(prefix, Ed25519KeysConst.xrpPubKeyPrefix) ||
BytesUtils.bytesEqual(prefix, Ed25519KeysConst.pubKeyPrefix)) {
return XRPKeyAlgorithm.ed25519;
}
if (Secp256k1PublicKeyEcdsa.isValidBytes(keyBytes)) {
Expand Down
2 changes: 1 addition & 1 deletion lib/src/rpc/on_chain_models/account_info.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import 'package:blockchain_utils/numbers/int_utils.dart';
import 'package:blockchain_utils/utils/numbers/utils/int_utils.dart';

class AccountInfo {
final AccountData accountData;
Expand Down
2 changes: 1 addition & 1 deletion lib/src/rpc/on_chain_models/ledger.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import 'package:blockchain_utils/numbers/numbers.dart';
import 'package:blockchain_utils/utils/utils.dart';
import 'package:xrpl_dart/src/xrpl/models/xrp_transactions.dart';

import 'on_chain_transaction.dart';
Expand Down
2 changes: 1 addition & 1 deletion lib/src/rpc/on_chain_models/ledger_info.dart
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import 'dart:math' as math;
import 'package:blockchain_utils/numbers/numbers.dart';
import 'package:blockchain_utils/utils/utils.dart';

enum XrplFeeType { open, minimum, dynamic }

Expand Down
2 changes: 1 addition & 1 deletion lib/src/rpc/on_chain_models/on_chain_transaction.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import 'package:blockchain_utils/numbers/numbers.dart';
import 'package:blockchain_utils/utils/utils.dart';

class TransactionData {
final String account;
Expand Down
2 changes: 1 addition & 1 deletion lib/src/rpc/on_chain_models/server_info.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import 'package:blockchain_utils/numbers/numbers.dart';
import 'package:blockchain_utils/utils/utils.dart';

class ServerInfo {
final Info info;
Expand Down
2 changes: 1 addition & 1 deletion lib/src/rpc/on_chain_models/server_state.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import 'package:blockchain_utils/numbers/numbers.dart';
import 'package:blockchain_utils/utils/utils.dart';

class XRPLedgerState {
final XRPLedgerStateDetails state;
Expand Down
2 changes: 1 addition & 1 deletion lib/src/rpc/on_chain_models/transaction_result.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import 'package:blockchain_utils/numbers/numbers.dart';
import 'package:blockchain_utils/utils/utils.dart';

class OnChainXRPLMemo {
final String? memoData;
Expand Down
4 changes: 3 additions & 1 deletion lib/src/utility/fulfillment/ans1/asn1_codec_exception.dart
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,7 @@ import 'package:blockchain_utils/exception/exceptions.dart';
class ASN1CodecException implements BlockchainUtilsException {
@override
final String message;
const ASN1CodecException(this.message);
@override
final Map<String, dynamic>? details;
const ASN1CodecException(this.message, {this.details});
}
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
OF THE POSSIBILITY OF SUCH DAMAGE.
*/

import 'package:blockchain_utils/binary/binary.dart';
import 'package:blockchain_utils/utils/utils.dart';
import 'package:xrpl_dart/src/xrpl/bytes/definations/field.dart';
import 'package:xrpl_dart/src/xrpl/exception/exceptions.dart';

Expand Down
2 changes: 1 addition & 1 deletion lib/src/xrpl/bytes/types/currency.dart
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class _CurrencyUtils {
if (bytes == null) return null;
if (bytes[0] != 0) {
return null;
} else if (bytesEqual(bytes, xrpIsoBytes)) {
} else if (BytesUtils.bytesEqual(bytes, xrpIsoBytes)) {
return xrpIsoName;
} else {
return _isoNameFromBytes(bytes.sublist(12, 15));
Expand Down
2 changes: 1 addition & 1 deletion lib/src/xrpl/bytes/types/hash.dart
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ abstract class Hash extends SerializedType {
if (identical(this, other)) return true;
return other is Hash &&
runtimeType == other.runtimeType &&
bytesEqual(_buffer, other._buffer);
BytesUtils.bytesEqual(_buffer, other._buffer);
}

@override
Expand Down
2 changes: 1 addition & 1 deletion lib/src/xrpl/bytes/types/xchain_bridge.dart
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ class XChainBridge extends SerializedType {
XChainBridge(List<int> buffer) : super(buffer);
@override
factory XChainBridge.fromValue(Map value) {
if (iterableIsEqual(value.keys, _XChainBridgeConst.keys)) {
if (CompareUtils.iterableIsEqual(value.keys, _XChainBridgeConst.keys)) {
final bytes = DynamicByteTracker();
for (final i in _XChainBridgeConst.keys) {
final buffer = _XChainBridgeConst.toBytesFromType(i, value[i]);
Expand Down
14 changes: 11 additions & 3 deletions lib/src/xrpl/exception/exceptions.dart
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,11 @@ import 'package:blockchain_utils/exception/exception.dart';
class XRPLBinaryCodecException implements BlockchainUtilsException {
@override
final String message;
@override
final Map<String, dynamic>? details;

/// Constructor for XRPLBinaryCodecException
const XRPLBinaryCodecException(this.message);
const XRPLBinaryCodecException(this.message, {this.details});

@override
String toString() => message;
Expand All @@ -17,8 +19,11 @@ class XRPLAddressCodecException implements BlockchainUtilsException {
@override
final String message;

@override
final Map<String, dynamic>? details;

/// Constructor for XRPLAddressCodecException
const XRPLAddressCodecException(this.message);
const XRPLAddressCodecException(this.message, {this.details});
@override
String toString() => message;
}
Expand All @@ -27,7 +32,10 @@ class XRPLTransactionException implements BlockchainUtilsException {
@override
final String message;

const XRPLTransactionException(this.message);
@override
final Map<String, dynamic>? details;

const XRPLTransactionException(this.message, {this.details});
@override
String toString() => message;
}
9 changes: 6 additions & 3 deletions lib/src/xrpl/models/base/transaction.dart
Original file line number Diff line number Diff line change
Expand Up @@ -370,10 +370,13 @@ class XRPTransaction extends XRPLBase {
factory XRPTransaction.fromBlob(String hexBlob) {
List<int> toBytes = BytesUtils.fromHexString(hexBlob);
final prefix = toBytes.sublist(0, 4);
if (bytesEqual(prefix, _TransactionUtils._transactionMultisigPrefix) ||
bytesEqual(prefix, _TransactionUtils._transactionSignaturePrefix)) {
if (BytesUtils.bytesEqual(
prefix, _TransactionUtils._transactionMultisigPrefix) ||
BytesUtils.bytesEqual(
prefix, _TransactionUtils._transactionSignaturePrefix)) {
toBytes = toBytes.sublist(4);
if (bytesEqual(prefix, _TransactionUtils._transactionMultisigPrefix)) {
if (BytesUtils.bytesEqual(
prefix, _TransactionUtils._transactionMultisigPrefix)) {
toBytes = toBytes.sublist(0, toBytes.length - Hash160.lengthBytes);
}
}
Expand Down
2 changes: 1 addition & 1 deletion lib/src/xrpl/models/escrow_create/escrow_create.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import 'package:blockchain_utils/numbers/numbers.dart';
import 'package:blockchain_utils/utils/utils.dart';
import 'package:xrpl_dart/src/utility/helper.dart';
import 'package:xrpl_dart/src/xrpl/models/xrp_transactions.dart';
import 'package:xrpl_dart/src/crypto/crypto.dart';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import 'package:blockchain_utils/numbers/numbers.dart';
import 'package:blockchain_utils/utils/utils.dart';
import 'package:xrpl_dart/src/utility/helper.dart';
import 'package:xrpl_dart/src/xrpl/models/xrp_transactions.dart';
import 'package:xrpl_dart/src/crypto/crypto.dart';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import 'package:blockchain_utils/numbers/numbers.dart';
import 'package:blockchain_utils/utils/utils.dart';
import 'package:xrpl_dart/src/utility/helper.dart';
import 'package:xrpl_dart/src/xrpl/models/xrp_transactions.dart';
import 'package:xrpl_dart/src/crypto/crypto.dart';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import 'package:blockchain_utils/numbers/numbers.dart';
import 'package:blockchain_utils/utils/utils.dart';
import 'package:xrpl_dart/src/xrpl/models/xrp_transactions.dart';
import 'package:xrpl_dart/src/crypto/crypto.dart';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import 'package:blockchain_utils/numbers/numbers.dart';
import 'package:blockchain_utils/utils/utils.dart';
import 'package:xrpl_dart/src/xrpl/models/xrp_transactions.dart';
import 'package:xrpl_dart/src/crypto/crypto.dart';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import 'package:blockchain_utils/numbers/numbers.dart';
import 'package:blockchain_utils/utils/utils.dart';
import 'package:xrpl_dart/src/xrpl/models/xrp_transactions.dart';
import 'package:xrpl_dart/src/crypto/crypto.dart';

Expand Down
2 changes: 1 addition & 1 deletion lib/src/xrpl/models/xchain/xchain_commit.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import 'package:blockchain_utils/numbers/numbers.dart';
import 'package:blockchain_utils/utils/utils.dart';
import 'package:xrpl_dart/src/xrpl/models/xrp_transactions.dart';
import 'package:xrpl_dart/src/crypto/crypto.dart';

Expand Down
2 changes: 1 addition & 1 deletion lib/src/xrpl/models/xchain/xchain_create_bridge.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import 'package:blockchain_utils/numbers/numbers.dart';
import 'package:blockchain_utils/utils/utils.dart';
import 'package:xrpl_dart/src/xrpl/models/xrp_transactions.dart';
import 'package:xrpl_dart/src/crypto/crypto.dart';

Expand Down
2 changes: 1 addition & 1 deletion lib/src/xrpl/models/xchain/xchain_create_claim_id.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import 'package:blockchain_utils/numbers/numbers.dart';
import 'package:blockchain_utils/utils/utils.dart';
import 'package:xrpl_dart/src/xrpl/models/xrp_transactions.dart';
import 'package:xrpl_dart/src/crypto/crypto.dart';

Expand Down
Loading

0 comments on commit 9293ccc

Please sign in to comment.