-
Notifications
You must be signed in to change notification settings - Fork 1.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
Cleanup social_handler.py #5245
Conversation
@sohje, thanks for your PR! By analyzing the annotation information on this pull request, we identified @solderzzc, @BreezeRo and @Jasperrr91 to be potential reviewers |
Why removed "need connect" and "connect again" debug messages? |
Cause it doesnt bring any clue whats happening. This PR is first step to refactor classes and methods. |
It certainly does bring a clue to what's happening... if the bot is constantly trying to reconnect, it can help to identify a connection issue. Also, would like to see debug messages use self.bot.config.debug
And of course use the logger to display messages. |
Refer to #5216 why these connect messages are useful. If nothing else, leave them there for now so we can remember to replace them with something much better later :) |
We can always check file history ;) |
If we enable printing via self.bot.config.debug there will be a lot of stuff by api requests, response etc. So i left DEBUG_ON module global var. |
Agree, but both are needed, so that debug messages are printed either if DEBUG_ON == True, OR config.debug == True. Both should work. In fact, probably easiest to just add:
to init section of each class |
Anyway, for now please at least add connect messages back because they are actually helpful in some situations. Happy to approve once done. |
Thanks. Approved. |
Ok, thanks. Merge then. |
Short Description:
Social_handler cleanup
Fixes/Resolves/Closes (please use correct syntax):