diff --git a/v4-client-py-v2/examples/validator_get_example.py b/v4-client-py-v2/examples/validator_get_example.py index e07216f5..5ec72179 100644 --- a/v4-client-py-v2/examples/validator_get_example.py +++ b/v4-client-py-v2/examples/validator_get_example.py @@ -7,13 +7,6 @@ async def test(): node_client = await NodeClient.connect(TESTNET.node) - try: - result = await node_client.get_account_balances(TEST_ADDRESS) - print("Get Account Balances:") - print(result) - except Exception as e: - print("Error in get_account_balances:") - print(f"Error: {e}") try: account = await node_client.get_account(TEST_ADDRESS) @@ -32,7 +25,7 @@ async def test(): print(f"Error: {e}") try: - response = await node_client.get_account_balance(TEST_ADDRESS, "usdc") + response = await node_client.get_account_balance(TEST_ADDRESS, "adv4tnt") print("Get Account Balance:") print(response) except Exception as e: diff --git a/v4-client-py-v2/examples/validator_post_example.py b/v4-client-py-v2/examples/validator_post_example.py index 6044e56f..d3dd32ec 100644 --- a/v4-client-py-v2/examples/validator_post_example.py +++ b/v4-client-py-v2/examples/validator_post_example.py @@ -4,12 +4,11 @@ import time from pathlib import Path -from dydx_v4_client import MAX_CLIENT_ID, NodeClient, Order, OrderFlags, Wallet -from dydx_v4_client.indexer.rest.indexer_client import IndexerClient +from dydx_v4_client import MAX_CLIENT_ID, NodeClient, Wallet from dydx_v4_client.network import TESTNET -from dydx_v4_client.node.market import Market from dydx_v4_client.node.message import order, order_id from tests.conftest import DYDX_TEST_MNEMONIC, TEST_ADDRESS +from google.protobuf.json_format import MessageToJson PERPETUAL_PAIR_BTC_USD = 0 @@ -51,7 +50,7 @@ async def test(): ), ) print("**Order Tx**") - print(place) + print(MessageToJson(place, always_print_fields_with_no_presence=True)) # FIXME: Remove wallet.sequence += 1 time.sleep(5)