-
Notifications
You must be signed in to change notification settings - Fork 5k
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
sendSignedTransaction never close websocket connection [1.2] #3094
Comments
@stefdelec Hi. You might be looking for web3.eth.sendSignedTransaction(result.rawTransaction)
.once("confirmation", (confirmationNumber, receipt) => {
// do something
}) In 1.2x, when you attach the confirmations handler using Closing - the web3 docs are reasonably clear about how PromiEvents work & what they are. |
Same behavior with |
@stefdelec If you're connecting to Ropsten could you look at #3104 and this comment to make sure that you're signing the transaction correctly for the Istanbul fork? |
The websocket connection stays established for the whole time. Otherwise we would have to connect and disconnect on each request. The wished behavior would also force us to re-establish subscriptions all the time. |
Description
When i call on sendSignedTransaction on nodejs, node process never ends because it seems that websocket connection is actually never closed.
It may lead to memory leak on server side.
Expected behavior
Expected behavior : To close websocketConnection, if I need only 'confirmation' event.
Actual behavior
Steps to reproduce the behavior
Launch nodejs process and see it never ends.
Versions
The text was updated successfully, but these errors were encountered: