Refactor codechecker_server#188
Open
furtib wants to merge 3 commits intoEricsson:mainfrom
Open
Conversation
0563010 to
32c6b45
Compare
Szelethus
approved these changes
May 4, 2026
| self.start_codechecker_server() | ||
|
|
||
| def __del__(self): | ||
| self.stop_codechecker_server() |
Contributor
There was a problem hiding this comment.
I admit I haven't spent terribly long with Python, but this might be the first time I've ever seen a destructor in the wild. My understanding is that, because of the garbage collector's unpredictability, this is not considered a Pythonic best practice. Even though your case is fine, as you call it explicitly, that kind of defeats the purpose of this function.
Then again, I'm not terribly opposed to it, because lingering zombie codechecker servers are quite annoying. Considering that we reuse the same server for all tests, this is likely fine.
32c6b45 to
939d260
Compare
974f5d4 to
46e4852
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why:
The CodeChecker server might stay alive as a zombie process if interrupted.
What:
Addresses:
Fixes: #186
#152