-
Notifications
You must be signed in to change notification settings - Fork 4k
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
aws logs tail --follow never exits #8576
Comments
i'm sorry but why is it a bug ? the log group still exists, thus, the logs tail --follow does not exits. If you need to do something programmatically, either trigger an SNS event when the task is finished or monitor its status inside your app |
Thanks for reaching out and your patience here. The tail command documentation notes the following for the
So if there are no more logs then I would expect the command to exit. Is this issue consistently reproducible? And outside of Fargate as well? Have you tried testing on more recent versions of the CLI? (The latest version per the CHANGELOG is 2.15.51.) There may be a delay in the ingestion of logs from the Fargate task to the CloudWatch Logs service. It's also possible that the log stream associated with the Fargate task is not being properly terminated or marked as complete, causing the If you can provide debug logs (with sensitive info redacted) by adding |
Greetings! It looks like this issue hasn’t been active in longer than five days. We encourage you to check if this is still an issue in the latest release. In the absence of more information, we will be closing this issue soon. If you find that this is still a problem, please feel free to provide a comment or upvote with a reaction on the initial post to prevent automatic closure. If the issue is already closed, please feel free to open a new one. |
Sorry for the late response. I'll make sure I'm on the latest version(s) and repro with the Stay tuned. |
Greetings! It looks like this issue hasn’t been active in longer than five days. We encourage you to check if this is still an issue in the latest release. In the absence of more information, we will be closing this issue soon. If you find that this is still a problem, please feel free to provide a comment or upvote with a reaction on the initial post to prevent automatic closure. If the issue is already closed, please feel free to open a new one. |
Describe the bug
aws logs tail <log_group> --log-stream-names <stream name> --follow
Never exits even tho no more logs are coming in due to the service (Fargate Task in this case) has exited.
This means I have to quit the command using Ctrl-C and hence can't use it programatically.
Expected Behavior
aws logs tail should time out when no more logs are coming in.
Current Behavior
aws logs tail <log_group> --log-stream-names <stream name> --follow
Never exits even tho no more logs are coming in due to the service (Fargate Task in this case) has exited.
Reproduction Steps
This is reproducibel on both Mac and Linux systems.
Possible Solution
No response
Additional Information/Context
No response
CLI version used
aws-cli/2.13.33 Python/3.11.6 Darwin/23.2.0 exe/x86_64 prompt/off
Environment details (OS name and version, etc.)
macOS (M2) Sonoma 14.2.1
The text was updated successfully, but these errors were encountered: