Skip to content

ref: Use atexit only in init#45

Merged
mitsuhiko merged 10 commits into
masterfrom
feature/atexit
Sep 1, 2018
Merged

ref: Use atexit only in init#45
mitsuhiko merged 10 commits into
masterfrom
feature/atexit

Conversation

@mitsuhiko
Copy link
Copy Markdown
Contributor

@mitsuhiko mitsuhiko commented Aug 31, 2018

This uses the same logic as the old raven python background worker which is to block in the atexit running thread on the lock the background worker has. This way the demon thread can be kept alive a while longer to orderly start the shutdown.

@mitsuhiko mitsuhiko requested a review from untitaker August 31, 2018 20:39
Comment thread sentry_sdk/consts.py Outdated
import socket


def default_shutdown_callback(pending, timeout):
Copy link
Copy Markdown
Member

@untitaker untitaker Sep 1, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the usecase for making this function configurable?

Comment thread sentry_sdk/utils.py


logger = logging.getLogger("sentry.errors")
logger = logging.getLogger("sentry_sdk.errors")
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

😬

@mitsuhiko
Copy link
Copy Markdown
Contributor Author

mitsuhiko commented Sep 1, 2018 via email

@mitsuhiko mitsuhiko merged commit fc6fc30 into master Sep 1, 2018
@untitaker untitaker deleted the feature/atexit branch September 1, 2018 16:12
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

Successfully merging this pull request may close these issues.

2 participants