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

Be quieter in expected shutdown cases #3261

Merged
merged 16 commits into from Jan 8, 2020
Merged

Be quieter in expected shutdown cases #3261

merged 16 commits into from Jan 8, 2020

Conversation

mikeshardmind
Copy link
Contributor

@mikeshardmind mikeshardmind commented Jan 3, 2020

Type

  • Bugfix
  • Enhancement
  • New feature

Description of the changes

  • shutdown/restart commands are less noisy.
  • quitting with keyboard interrupt is warned against, then handled as best as possible.

@mikeshardmind mikeshardmind added the Type: Enhancement label Jan 3, 2020
@mikeshardmind mikeshardmind added this to the 3.2.0 milestone Jan 3, 2020
Drapersniper
Drapersniper previously approved these changes Jan 3, 2020
Copy link
Contributor

@Drapersniper Drapersniper left a comment

LGTM, also fixed spam in logs i was seeing during a restart

@mikeshardmind mikeshardmind added the Release Blocker label Jan 3, 2020
@Drapersniper
Copy link
Contributor

@Drapersniper Drapersniper commented Jan 3, 2020

During graceful shudowns shudowns are a lot faster on windows.

Forced shutdowns are significantly faster than before too however some times if python is interacting with a task it will throw a trace after shutting the bot down.

image

This is not the case 100% of the time, however we are warning the user with Please do not use Ctrl+C to Shutdown Red! (attempting to die gracefully...) as its an attempt for a graceful shutdown and they are warned to not use Ctrl+C so this PR look fine if we are okay with the traces being raise some times on Windows.

Drapersniper
Drapersniper previously approved these changes Jan 3, 2020
@jack1142
Copy link
Member

@jack1142 jack1142 commented Jan 5, 2020

I still don't have a graceful shutdown with this PR, getting this when using [p]shutdown with non-0 exit code:

ExitCodes.SHUTDOWN
CRITICAL:root:Caught unhandled exception: ExitCodes.SHUTDOWN

redbot/__main__.py Outdated Show resolved Hide resolved
@mikeshardmind
Copy link
Contributor Author

@mikeshardmind mikeshardmind commented Jan 5, 2020

Proactor event loop has an issue right now not ignoring already being closed. I'll handle this later tonight, and contribute upstream if it doesnt already have someone assigned.

Kowlin
Kowlin approved these changes Jan 8, 2020
Copy link
Member

@Kowlin Kowlin left a comment

Working as intended.

@Kowlin Kowlin merged commit 35c27c5 into Cog-Creators:V3/develop Jan 8, 2020
2 checks passed
@mikeshardmind mikeshardmind deleted the more-loop-cleanup branch Jan 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Release Blocker Type: Enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants