-
Notifications
You must be signed in to change notification settings - Fork 41
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
Error when I relay a transaction with walletRpc #36
Comments
From the daemon terminal, this error is expected: "!boost::string_ref{sig_str}.starts_with(header_v1) && !boost::string_ref{sig_str}.starts_with(header_v2). THROW EXCEPTION: error::wallet_internal_error" (see related issue). However, the "tx_rejected" from means the submitted tx was invalid and rejected by the daemon. I tested locally and was able to create then relay 50 txs in a row without any problem, so I'm not able to reproduce the issue. Is your code multithreaded at all? |
How did you create 50 txs and relay them without bumping into the 10 block lock time after the first transaction? I know you can send up to 16 outputs from an input but for now i just want to be able to send 10 Tx without an error. MoneroWalletRpc walletRpc = new MoneroWalletRpc("http://localhost:38083", "rpc_user", "abc123");
and this is what i get in return : Transaction1 b1c5ab4bc0827a608e607f039b47722d404c9fd2085e8817f6038ac30fb0b540 relayed the first transaction goes without a problem but after i change to another wallet and want to broadcast the second transaction it doesn't work. What should i do ? |
I had a test wallet with >50 unspent outputs, so they could all be sent in rapid succession. I'm still not able to reproduce the error. Please enable logging in the daemon with |
Closing as stale. |
Sending an unique transaction is fine, but if i try to send a few in a row, if i don't put a TimeUnit.SECONDS.sleep(10) before and after the relay function I get this error: Exception in thread "main" -4: Failed to commit tx. RPC request: 'relay_tx' with params: {"hex":"the transaction hex"}.
in the command prompt i get this multiple lines with this: "2022-04-15 06:56:19.730 E daemon_send_resp.status != CORE_RPC_STATUS_OK. THROW EXCEPTION: error::tx_rejected
2022-04-15 06:56:19.741 E !boost::string_ref{sig_str}.starts_with(header_v1) && !boost::string_ref{sig_str}.starts_with(header_v2). THROW EXCEPTION: error::wallet_internal_error
"
Even with the delay, sometimes randomly the transaction fails and i get this error, it is very random. How should i fix it ?
I also check the fee before relaying the Tx, and to send multiple transactions on Stagenet I also have multiple funded wallets that i switch after there are no more unlocked funds. I use walletRpc.openWallet() and walletRpc.close()
MoneroTxWallet createdTx = walletRpc.createTx(new MoneroTxConfig()
.setAccountIndex(0)
.setAddress("some_address")
.setAmount("some_amount").setRelay(false));
TimeUnit.SECONDS.sleep(10);
walletRpc.relayTx(createdTx);
TimeUnit.SECONDS.sleep(10);
The text was updated successfully, but these errors were encountered: