scratchattach icon indicating copy to clipboard operation
scratchattach copied to clipboard

My bot is constantly connecting and disconnecting from TurboWarp's cloud unintentionally

Open y-nk0427 opened this issue 1 year ago • 7 comments

https://scratch.mit.edu/projects/1064835367/#comments-447726347

GarboMuffin wrote:

Hi there is some bot constantly connecting and disconnecting to this project on TurboWarp's cloud variable server. If you are the person running that bot can you please change it so that you open one connection instead of constantly opening and closing new ones or wait like 10 seconds between each connection. I really don't like blocking bots.

So I checked my bot's code, but it was like this:

  • s3_connection_tw = s3_session.connect_tw_cloud(1064835367, purpose=..., contact=...) runs only once outside an infinite loop
  • After that, always uses s3_connection_tw.set_var(name, value) when assigning to cloud variables

Why is this code constantly connecting and disconnecting?

y-nk0427 avatar Jan 24 '25 11:01 y-nk0427

Would you show the complete code

y_nk @.***> schrieb am Fr., 24. Jan. 2025, 12:37:

https://scratch.mit.edu/projects/1064835367/#comments-447726347

GarboMuffin wrote:

Hi there is some bot constantly connecting and disconnecting to this project on TurboWarp's cloud variable server. If you are the person running that bot can you please change it so that you open one connection instead of constantly opening and closing new ones or wait like 10 seconds between each connection. I really don't like blocking bots.

So I checked my bot's code, but it was like this:

  • s3_connection_tw = s3_session.connect_tw_cloud(1064835367, purpose=..., contact=...) runs only once outside an infinite loop
  • After that, always uses s3_connection_tw.set_var(name, value) when assigning to cloud variables

Why is this code constantly connecting and disconnecting?

— Reply to this email directly, view it on GitHub https://github.com/TimMcCool/scratchattach/issues/335, or unsubscribe https://github.com/notifications/unsubscribe-auth/ATCKMZSEZZSYXTGS4BEVHT32MIQXNAVCNFSM6AAAAABVZPPML6VHI2DSMVQWIX3LMV43ASLTON2WKOZSHAYDSMRSGUYTGMA . You are receiving this because you are subscribed to this thread.Message ID: @.***>

TheCommCraft avatar Jan 24 '25 11:01 TheCommCraft

Here you are. https://github.com/y-nk0427/ProjectIDLiveCounter/blob/main/ProjectIDLive.py (Running on bot-hosting.net)

y-nk0427 avatar Jan 25 '25 02:01 y-nk0427

Maybe add a print statement before the turbowarp cloud connection line and look if the line gets run multiple times

TheCommCraft avatar Jan 25 '25 10:01 TheCommCraft

Added print("Trying to connect") before s3_connection_tw = s3_session.connect_tw_cloud(...) but this ran only once. I think this issue might be due to the mechanism of scratchattach itself.

y-nk0427 avatar Jan 25 '25 11:01 y-nk0427

Maybe the connection just isn't stable where you are hosting

y_nk @.***> schrieb am Sa., 25. Jan. 2025, 12:44:

Added print("Trying to connect") before s3_connection_tw = s3_session.connect_tw_cloud(...) but this ran only once. I think this issue might be due to the mechanism of scratchattach itself.

— Reply to this email directly, view it on GitHub https://github.com/TimMcCool/scratchattach/issues/335#issuecomment-2613938429, or unsubscribe https://github.com/notifications/unsubscribe-auth/ATCKMZVQCRWWDMZ5FCZG2N32MN2I5AVCNFSM6AAAAABVZPPML6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDMMJTHEZTQNBSHE . You are receiving this because you commented.Message ID: @.***>

TheCommCraft avatar Jan 25 '25 11:01 TheCommCraft

Maybe try hosting it on something else a bit

y_nk @.***> schrieb am Sa., 25. Jan. 2025, 12:44:

Added print("Trying to connect") before s3_connection_tw = s3_session.connect_tw_cloud(...) but this ran only once. I think this issue might be due to the mechanism of scratchattach itself.

— Reply to this email directly, view it on GitHub https://github.com/TimMcCool/scratchattach/issues/335#issuecomment-2613938429, or unsubscribe https://github.com/notifications/unsubscribe-auth/ATCKMZVQCRWWDMZ5FCZG2N32MN2I5AVCNFSM6AAAAABVZPPML6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDMMJTHEZTQNBSHE . You are receiving this because you commented.Message ID: @.***>

TheCommCraft avatar Jan 25 '25 11:01 TheCommCraft

Try doing an internet speed test if your hosting locally. Stop the script and make sure you tell Garbo muffin tots is not on purpose. If necessary, consider hosting your own cloud server using the special sa feature for that to test the script and debit it without spamming tw

DagriffpatchfanHosting avatar Jan 27 '25 08:01 DagriffpatchfanHosting

stale. if you have this issue, make a new issue

faretek1 avatar Sep 29 '25 23:09 faretek1