Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wallet V5 , Tonlib.getAccountState() always returns seqno = 0 #78

Open
Zhenya-Bazyleu opened this issue Nov 12, 2024 · 2 comments
Open

Comments

@Zhenya-Bazyleu
Copy link

No description provided.

@neodix42
Copy link
Owner

please provide the information on how you deployed the wallet and the link to it on a testnet.

@Zhenya-Bazyleu
Copy link
Author

Tonlib Initialization :

Tonlib tonlib = Tonlib.builder()
                    .pathToTonlibSharedLib(pathToTonlibSharedLib)
                    .verbosityLevel(VerbosityLevel.FATAL)
                    .testnet( true )
                    .ignoreCache(false)
                    .build();

WalletV5 :

static final long WALLET_ID_V5_MAINNET = 2147483409L;
static final long WALLET_ID_V5_TESTNET = 2147483645L;

if (testNet) {
            walletId = WALLET_ID_V5_TESTNET;
} else {
            walletId = WALLET_ID_V5_MAINNET;
}

WalletV5 walletBase = WalletV5.builder()
                .wc(0)
                .walletId(walletId)
                .keyPair(keyPair)
                .isSigAuthAllowed(true)
                .tonlib(tonlib)
                .build();

It works perfectly :
long seqno1 = walletBase.getSeqno(); // It works perfectly

It always equals 0 :

FullAccountState accountState = walletBase.getTonlib().getAccountState(walletBase.getAddress());
AccountState account = accountState.getAccount_state();
int seqno = account.getSeqno(); // It always equals 0

My wallet V5 :

https://testnet.tonviewer.com/kQDLET9znJ2N2iJja5oB8DeEdTvzKlgHzIKGk4XERvXMX3Nm

Thank you!
Zhenya

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants