-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Logging done late enough might happen when capture already stopped. #4487
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @s0undt3ch, thanks a lot for the PR.
Could you provide a simple integration test which reproduces the problem? It is important to avoid future regressions in case of a refactoring (for example).
@nicoddemus believe me, I tried, for sure not long enough or there would be a test case. Anyway, I wasn't able to reproduce this in a test case :\ |
Hmm I see, thanks. I've tried here myself as well using IMHO we can get this in as it makes the code more consistent with |
Codecov Report
@@ Coverage Diff @@
## master #4487 +/- ##
===========================================
- Coverage 95.9% 42.54% -53.37%
===========================================
Files 111 92 -19
Lines 25085 20844 -4241
Branches 2447 2337 -110
===========================================
- Hits 24059 8868 -15191
- Misses 724 11383 +10659
- Partials 302 593 +291
Continue to review full report at Codecov.
|
@RonnyPfannschmidt @asottile @blueyed any objections to get this in without an acceptance test? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure how difficult a test would be, but it certainly would be great to have for corner cases like this.
changelog/4487.bugfix.rst
Outdated
@@ -0,0 +1 @@ | |||
During teardown of the python process, capture attributes are None'd. On rare occasions global capture could be attempted to resume while is't already reset. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/is't/it's/
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and probably ``None``
as well
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/are None'd/that are ``None``/ ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
``None``'d
I think is correct
Definitely, would you like to give this a try? I've tried for a few minutes to get this error to blow up with |
@nicoddemus |
Comment and changelog entry reworded. |
Thanks! |
Anytime, and Thanks! |
@s0undt3ch i believe someone found a minimal test in #4500 |
Awesome! |
changelog
folder, with a name like<ISSUE NUMBER>.<TYPE>.rst
. See changelog/README.rst for details.master
branch for bug fixes, documentation updates and trivial changes.