-
-
Notifications
You must be signed in to change notification settings - Fork 547
Fix: Thread-safe get_root() with deterministic ordering and proper logging (Issue #3098) #3158
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
Open
RaviTeja799
wants to merge
11
commits into
intelowlproject:develop
Choose a base branch
from
RaviTeja799:fix/issue-3098-thread-safety
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 10 commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
79074ca
refactor: implement thread-safe get_root with deterministic ordering
RaviTeja799 3f861ea
style: fix Black formatting in get_root() and test file
RaviTeja799 1eb21c7
test: fix test to use mock.patch for MultipleObjectsReturned exception
RaviTeja799 eef87eb
test: use raw SQL to create duplicate root for MultipleObjectsReturne…
RaviTeja799 1d90d45
style: fix isort import formatting
RaviTeja799 c680937
test: use mocking to test MultipleObjectsReturned handling in get_root()
RaviTeja799 5d5a841
test: use mocking to test MultipleObjectsReturned handling in get_root()
RaviTeja799 725ee9b
fix: use patch.object for proper mocking of super().get_root() call
RaviTeja799 0749ef3
fix: re-enable logging for test as CI disables it via DISABLE_LOGGING…
RaviTeja799 5940664
fix(tests): use mock logger instead of assertLogs for CI compatibility
RaviTeja799 4f6a679
refactor: change logger.error to logger.warning per review
RaviTeja799 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
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
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
Oops, something went wrong.
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.
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.
I would just raise a warning here, we don't know how much noisy this can be
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 @mlodic!
That is a valuable suggestion thanks for the help and support. I would definitely follow you advice to avoid creating unnecessary noise in the logs. I've updated the code to use logger.warning instead of logger.error as you suggested.
I also updated the new test case to reflect this change so the CI stays green. Thanks for the feedback!