https://prefect.io logo
Title
m

Marius Haberstock

08/01/2022, 9:19 AM
What I really liked about Prefect 1.0 was the
log_to_stdout
Parameter which automatically logs all print statements. Is there something similar for Prefect 2?
1
a

Anna Geller

08/01/2022, 10:36 AM
no, not at the moment you need to use logger - in the end it's one line
logger = get_run_logger()
j

John

10/08/2022, 12:07 PM
This does require refactoring all
print()
statements to
<http://logger.info|logger.info>()
, doesn't it?
One of the most appealing feature of Prefect is that I don't have to refactor existing code to work with Prefect, and that I can run the code locally without involving Prefect at all. I would love to see
log_stdout
feature back in Prefect 2.
a

Anna Geller

10/10/2022, 11:50 AM
I agree, I'm gonna put this into our product backlog for prioritization and talk internally how/when we can address it - thanks for reminding about this, definitely very important
🙌 1
❤️ 1