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

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

Open
y-nk0427 opened this issue Jan 24, 2025 · 7 comments

Comments

@y-nk0427
Copy link

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?

@TheCommCraft
Copy link
Collaborator

TheCommCraft commented Jan 24, 2025 via email

@y-nk0427
Copy link
Author

y-nk0427 commented Jan 25, 2025

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

@TheCommCraft
Copy link
Collaborator

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

@y-nk0427
Copy link
Author

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.

@TheCommCraft
Copy link
Collaborator

TheCommCraft commented Jan 25, 2025 via email

@TheCommCraft
Copy link
Collaborator

TheCommCraft commented Jan 25, 2025 via email

@DagriffpatchfanHosting
Copy link

DagriffpatchfanHosting commented Jan 27, 2025

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

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

3 participants