Skip to content
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

Replace Python print statements with logging to StreamHandler #2319

Closed
jim-sheldon opened this issue Dec 9, 2021 · 1 comment
Closed

Replace Python print statements with logging to StreamHandler #2319

jim-sheldon opened this issue Dec 9, 2021 · 1 comment
Assignees
Labels
Bug Infrastructure Issues related to AWS/EKS/Docker etc P1: Launch blocker Needs fixing before we launch, schedule some time to investigate & fix Tech Debt
Milestone

Comments

@jim-sheldon
Copy link
Collaborator

Calling print in Python does not automatically write its output to stdout; when a script runs in Docker and hangs on a line, it can result in a timeout with incomplete (even no) output written to Cloudwatch logs.
We should use logging instead of print statements, and we need to use a StreamHandler to ensure each log statement gets flushed from the buffer and made visible in Cloudwatch.

https://docs.python.org/3/library/logging.handlers.html#streamhandler

@jim-sheldon jim-sheldon added P0: Critical path blocker Blocking testing or the launch critical path, drop everything to investigate & fix Infrastructure Issues related to AWS/EKS/Docker etc Bug Tech Debt labels Dec 9, 2021
@jim-sheldon jim-sheldon added this to the Lewis milestone Dec 9, 2021
@jim-sheldon jim-sheldon self-assigned this Dec 9, 2021
abhidg added a commit that referenced this issue Dec 13, 2021
* Possible fix for #1877
* Add logging using StreamHandler #2319
abhidg added a commit that referenced this issue Dec 13, 2021
* Possible fix for #1877
* Add logging using StreamHandler #2319
abhidg added a commit that referenced this issue Dec 13, 2021
* Possible fix for #1877
* Add logging using StreamHandler #2319
abhidg added a commit that referenced this issue Dec 13, 2021
* Possible fix for #1877
* Add logging using StreamHandler #2319
iamleeg pushed a commit that referenced this issue Dec 16, 2021
* Possible fix for #1877
* Add logging using StreamHandler #2319
@joe-brilliant joe-brilliant added P1: Launch blocker Needs fixing before we launch, schedule some time to investigate & fix and removed P0: Critical path blocker Blocking testing or the launch critical path, drop everything to investigate & fix labels Jan 11, 2022
@joe-brilliant joe-brilliant modified the milestones: Lewis, Leonidas Feb 1, 2022
@iamleeg iamleeg self-assigned this Feb 15, 2022
@iamleeg
Copy link
Contributor

iamleeg commented Feb 15, 2022

Looks like there's still stuff to do in ingestion, I'll take that on.

iamleeg added a commit that referenced this issue Feb 16, 2022
iamleeg added a commit that referenced this issue Feb 16, 2022
iamleeg added a commit that referenced this issue Feb 16, 2022
iamleeg added a commit that referenced this issue Feb 16, 2022
@iamleeg iamleeg closed this as completed Feb 16, 2022
abhidg added a commit that referenced this issue Feb 18, 2022
abhidg added a commit that referenced this issue Feb 18, 2022
abhidg added a commit that referenced this issue Feb 18, 2022
abhidg added a commit that referenced this issue Feb 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Infrastructure Issues related to AWS/EKS/Docker etc P1: Launch blocker Needs fixing before we launch, schedule some time to investigate & fix Tech Debt
Projects
None yet
Development

No branches or pull requests

3 participants