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

Ensure Python app can handle SIGTERM/SIGKILL #115

Closed
halajohn opened this issue Oct 13, 2024 · 2 comments
Closed

Ensure Python app can handle SIGTERM/SIGKILL #115

halajohn opened this issue Oct 13, 2024 · 2 comments
Assignees
Labels
enhancement New feature or request

Comments

@halajohn
Copy link
Member

Go app had special handling for these signals.

@halajohn halajohn added the enhancement New feature or request label Oct 13, 2024
@halajohn halajohn added this to Kanban Oct 13, 2024
@halajohn halajohn moved this to Todo in Kanban Oct 13, 2024
@sunxilin
Copy link
Collaborator

The current status is that TEN Python app can handle SIGTERM/SIGKILL as the TEN signal handler is registered after the library 'libten_runtime' is loaded. The performance is that 'ctrl+C' will trigger the TEN app gracefully close.

@halajohn
Copy link
Member Author

The signal handler registered in ten_runtime's on_load will not be overwritten in the Python environment. Therefore, in a Python TEN app, pressing Ctrl-C once will stop the app, and pressing Ctrl-C twice will forcibly exit the TEN app. Both behaviors are effective.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: Done
Development

No branches or pull requests

2 participants