This repository has been archived by the owner on May 25, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 43
fix iteration #413
Merged
djaglowski
merged 3 commits into
open-telemetry:main
from
rockb1017:filelog_fix_iteration
Feb 25, 2022
Merged
fix iteration #413
djaglowski
merged 3 commits into
open-telemetry:main
from
rockb1017:filelog_fix_iteration
Feb 25, 2022
Conversation
This file contains 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
Codecov Report
@@ Coverage Diff @@
## main #413 +/- ##
=====================================
Coverage 75.1% 75.2%
=====================================
Files 83 83
Lines 4022 4025 +3
=====================================
+ Hits 3023 3028 +5
+ Misses 696 694 -2
Partials 303 303
|
djaglowski
reviewed
Feb 23, 2022
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.
@rockb1017 This is a great find and fix.
Two things:
- See comment on the
if
condition. If I'm right, we can remove it and have a much clearer diff. - Do you have any way to reproduce the unwanted behavior in tests? I would hate for a future change to undo this fix. (I acknowledge this function is doing too much and should be pulled apart to make it more testable, but perhaps a higher level test can catch it for now.)
i have applied your suggestion. Thank you. |
4ea9cff
to
9d2414e
Compare
djaglowski
approved these changes
Feb 25, 2022
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.
LGTM. Thanks @rockb1017
4 tasks
jsirianni
pushed a commit
to jsirianni/opentelemetry-log-collection
that referenced
this pull request
Mar 28, 2022
* fix iteration * remove unneccesary if * add a test case
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Fixes #391
with this change, data duplication is gone.
it is iterating over an array, but we are removing elements from that very array, so it causes to skip the next element after removing.