Repository navigation
fix(core): forward nextToken when paging log streams in _flush_log_streams - #6447
Open
AkshayShah03 wants to merge 1 commit into
Open
AkshayShah03 wants to merge 1 commit into
AkshayShah03 wants to merge 1 commit into
Conversation
…reams _flush_log_streams pages through DescribeLogStreams while the response has a nextToken, but never passed that token back. Each call returned the same first page again, so for a job with more log streams than one page (more than 50 instances, or more streams than min(instance_count, 50)) the loop never ended and stream_names kept growing, hanging wait(logs=True) and log tailing. Pass nextToken in all three copies (common_utils, session_helper and remote_function.job).
AkshayShah03
requested a deployment
to
manual-approval
October 12, 2026 17:59 — with
GitHub Actions
Waiting
AkshayShah03
requested a deployment
to
manual-approval
October 12, 2026 17:59 — with
GitHub Actions
Waiting
AkshayShah03
requested a deployment
to
manual-approval
October 12, 2026 18:00 — with
GitHub Actions
Waiting
This branch is waiting to be deployed
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.
Issue #, if available: N/A
Description of changes:
_flush_log_streamspages throughDescribeLogStreamswhile the response has anextToken, but never passes the token back:Every call returns the first page again. For a job with more log streams than one page holds (more than 50 instances, or more streams than
min(instance_count, 50)), the loop never ends andstream_nameskeeps growing, which hangswait(logs=True)and log tailing.This change passes
nextToken=streams["nextToken"]in all three copies of this function:common_utils,helper/session_helperandremote_function/job.Testing:
tests/unit/test_flush_log_streams.py, parametrized over the three modules, uses a paginating fake client with 60 streams. All 60 are picked up in 2 calls. All three fail before this change.By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.