forza-panino / Sniper-Bot

This free-to-use bot allows you to snipe every token presale on DxSale, Pinksale or any other BSC platform where you have to send BNB to some presale address.
Other
89 stars 37 forks source link

fails after waiting for launch #2

Closed jorgyporgy closed 2 years ago

jorgyporgy commented 2 years ago

Wouldve left it in the previous one, but "13:00" is not accepted as 1pm. Is that wrong? After about 2 minutes of "waiting for time to come" it fails

forza-panino commented 2 years ago

Please, add more information Did you insert 13 and then 00 as time of presale start? At what time did you set it up? Furthermore, what do you mean by "it fails"? Did it show an error message (and what did it say) or it just didn't nothing at all?

jorgyporgy commented 2 years ago

You have launched the bot with the following settings: Mode: presale Delay: off Net: mainnet Do you want to change number of delay blocks? (y/n): n Delay blocks number has not been changed.

Checking wallet configuration... Found the following wallet configuration: Private key: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx Gas amount: 150000 Gas price: 6.5 Amount: .1 Do you want to change wallet configuration? (y/n): n

Starting presale bot with the chosen settings... Insert target address: 0x63Fc70AEc865ef29B9B3fEf97d67B5A85b7EDFAC You digited 0x63Fc70AEc865ef29B9B3fEf97d67B5A85b7EDFAC (PRESALE ADDY CONTRACT) Confirm? (y/n): y

You will now be asked for time of presale start. Please, use your LOCAL TIME. Insert start hour: 13: You digited 13 Confirm? (y/n): y Insert start minute: :00 Not a number. Insert start minute: 00 You digited 0 Confirm? (y/n): y Time of presale start has been set to 13:0 LOCAL TIME. Waiting for time to come... /home/USER/Sniper-Bot-main/node_modules/web3-core-helpers/lib/errors.js:43 return new Error(message); ^

Error: Invalid JSON RPC response: "" at Object.InvalidResponse (/home/USER/Sniper-Bot-main/node_modules/web3-core-helpers/lib/errors.js:43:16) at XMLHttpRequest.request.onreadystatechange (/home/USER/Sniper-Bot-main/node_modules/web3-providers-http/lib/index.js:95:32) at XMLHttpRequestEventTarget.dispatchEvent (/home/USER/Sniper-Bot-main/node_modules/xhr2-cookies/dist/xml-http-request-event-target.js:34:22) at XMLHttpRequest._setReadyState (/home/USER/Sniper-Bot-main/node_modules/xhr2-cookies/dist/xml-http-request.js:208:14) at XMLHttpRequest._onHttpRequestError (/home/USER/Sniper-Bot-main/node_modules/xhr2-cookies/dist/xml-http-request.js:349:14) at ClientRequest. (/home/USER/Sniper-Bot-main/node_modules/xhr2-cookies/dist/xml-http-request.js:252:61) at ClientRequest.emit (node:events:390:28) at TLSSocket.socketErrorListener (node:_http_client:447:9) at TLSSocket.emit (node:events:390:28) at emitErrorNT (node:internal/streams/destroy:164:8) at emitErrorCloseNT (node:internal/streams/destroy:129:3) at processTicksAndRejections (node:internal/process/task_queues:83:21)

Node.js v17.0.1 USER@USER-ThinkPad-P1:~/Sniper-Bot-main$ ^C

forza-panino commented 2 years ago

The issue may be the gas price, can you try next time to set it to 10 (minimum)? I know that with a gas price lower than 10 GWEI/unit occurs an error, but I'm still trying to understand if it's a bug of the bot, the web3js library or the endpoint

jorgyporgy commented 2 years ago

10 gwei still did not work. is 150000 ok ?

jorgyporgy commented 2 years ago

Here's the new wallet configuration: Private key: PRIVATEKEY Gas amount: 150000 Gas price: 10 Amount: .15

Starting presale bot with the chosen settings... Insert target address: 0x63Fc70AEc865ef29B9B3fEf97d67B5A85b7EDFAC You digited 0x63Fc70AEc865ef29B9B3fEf97d67B5A85b7EDFAC Confirm? (y/n): y

You will now be asked for time of presale start. Please, use your LOCAL TIME. Insert start hour: 13 You digited 13 Confirm? (y/n): y Insert start minute: 00 You digited 0 Confirm? (y/n): y Time of presale start has been set to 13:0 LOCAL TIME. Waiting for time to come... /home/USER/Sniper-Bot-main/node_modules/web3-core-helpers/lib/errors.js:43 return new Error(message); ^

Error: Invalid JSON RPC response: "\r\n403 Forbidden\r\n\r\n

403 Forbidden

\r\n\r\n\r\n" at Object.InvalidResponse (/home/USER/Sniper-Bot-main/node_modules/web3-core-helpers/lib/errors.js:43:16) at XMLHttpRequest.request.onreadystatechange (/home/USER/Sniper-Bot-main/node_modules/web3-providers-http/lib/index.js:95:32) at XMLHttpRequestEventTarget.dispatchEvent (/home/USER/Sniper-Bot-main/node_modules/xhr2-cookies/dist/xml-http-request-event-target.js:34:22) at XMLHttpRequest._setReadyState (/home/USER/Sniper-Bot-main/node_modules/xhr2-cookies/dist/xml-http-request.js:208:14) at XMLHttpRequest._onHttpResponseEnd (/home/USER/Sniper-Bot-main/node_modules/xhr2-cookies/dist/xml-http-request.js:318:14) at IncomingMessage. (/home/USER/Sniper-Bot-main/node_modules/xhr2-cookies/dist/xml-http-request.js:289:61) at IncomingMessage.emit (node:events:402:35) at endReadableNT (node:internal/streams/readable:1340:12) at processTicksAndRejections (node:internal/process/task_queues:83:21)

forza-panino commented 2 years ago

I don't think it's gas-amount related, more likely to be an error with the http provider Unfortunately, I've tried but I didn't manage to reproduce this kind of error (neither I have never received such an error during my test phase); I will dig further, if it happens again feel free to write it here again

maddefientist commented 2 years ago

Thanks, it hasn't been successful for me as of yet. Maybe ill tinker with network settings for now.

John7481 commented 2 years ago

You have launched the bot with the following settings: Mode: presale Delay: off Net: mainnet Do you want to change number of delay blocks? (y/n): n Delay blocks number has not been changed.

Checking wallet configuration... Found the following wallet configuration: Private key: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx Gas amount: 150000 Gas price: 6.5 Amount: .1 Do you want to change wallet configuration? (y/n): n

Starting presale bot with the chosen settings... Insert target address: 0x63Fc70AEc865ef29B9B3fEf97d67B5A85b7EDFAC You digited 0x63Fc70AEc865ef29B9B3fEf97d67B5A85b7EDFAC (PRESALE ADDY CONTRACT) Confirm? (y/n): y

You will now be asked for time of presale start. Please, use your LOCAL TIME. Insert start hour: 13: You digited 13 Confirm? (y/n): y Insert start minute: :00 Not a number. Insert start minute: 00 You digited 0 Confirm? (y/n): y Time of presale start has been set to 13:0 LOCAL TIME. Waiting for time to come... /home/USER/Sniper-Bot-main/node_modules/web3-core-helpers/lib/errors.js:43 return new Error(message); ^

Error: Invalid JSON RPC response: "" at Object.InvalidResponse (/home/USER/Sniper-Bot-main/node_modules/web3-core-helpers/lib/errors.js:43:16) at XMLHttpRequest.request.onreadystatechange (/home/USER/Sniper-Bot-main/node_modules/web3-providers-http/lib/index.js:95:32) at XMLHttpRequestEventTarget.dispatchEvent (/home/USER/Sniper-Bot-main/node_modules/xhr2-cookies/dist/xml-http-request-event-target.js:34:22) at XMLHttpRequest._setReadyState (/home/USER/Sniper-Bot-main/node_modules/xhr2-cookies/dist/xml-http-request.js:208:14) at XMLHttpRequest._onHttpRequestError (/home/USER/Sniper-Bot-main/node_modules/xhr2-cookies/dist/xml-http-request.js:349:14) at ClientRequest. (/home/USER/Sniper-Bot-main/node_modules/xhr2-cookies/dist/xml-http-request.js:252:61) at ClientRequest.emit (node:events:390:28) at TLSSocket.socketErrorListener (node:_http_client:447:9) at TLSSocket.emit (node:events:390:28) at emitErrorNT (node:internal/streams/destroy:164:8) at emitErrorCloseNT (node:internal/streams/destroy:129:3) at processTicksAndRejections (node:internal/process/task_queues:83:21)

Node.js v17.0.1 USER@USER-ThinkPad-P1:~/Sniper-Bot-main$ ^C

I have similar issue. I used even higher GWEI = 61 and gas_amount=700000

forza-panino commented 2 years ago

The "forbidden" error should now be solved. Can you guys please check if you're still having the error concerning the void rpc response? Update with last commit 3ca5ce6

John7481 commented 2 years ago

The "forbidden" error should now be solved. Can you guys please check if you're still having the error concerning the void rpc response? Update with last commit 3ca5ce6

Now I don't have an opportunity to use it in the practice. Once something appear I let you know. Thanks for the fix.

forza-panino commented 2 years ago

If you want to test the correct behaviour of the bot before future presales you can also send money to yourself just by setting your wallet's address as target address.

With 10GWEI I paid just 0.17$ per tx and, at least for me, it seems to be working well

John7481 commented 2 years ago

If you want to test the correct behaviour of the bot before future presales you can also send money to yourself just by setting your wallet's address as target address.

With 10GWEI I paid just 0.17$ per tx and, at least for me, it seems to be working well

Test on my wallet finished successfully. Thanks for the modification.

forza-panino commented 2 years ago

Issue solved with commit 3ca5ce6