So, I finished the lab on Airflow Best practices, which introduces 2 DAGS(Simple and Grouped Tasks). Everything works fine as expected, but I decided to be curious to see the Logs to confirm the notifications if it executed the print statements for each of the notification task on each DAG.
The expected format is supposed to follow this print statement below:
print(f"Number of valid records in table {table}: {valid_records}")
But when I check the logs for the notification task, I see something in the print statement that makes me wonder if this is normal since its against a database or is there a way to actually retrieve the value.
This is what I saw in the logs:
2025-01-23, 02:20:58 UTC] {logging_mixin.py:190} INFO - Number of valid records in table payments: LazySelectSequence([1 item])
[2025-01-23, 02:20:58 UTC] {logging_mixin.py:190} INFO - Number of valid records in table customers: LazySelectSequence([1 item])
[2025-01-23, 02:20:58 UTC] {logging_mixin.py:190} INFO - Number of valid records in table products: LazySelectSequence([1 item])
[2025-01-23, 02:20:58 UTC] {python.py:240} INFO - Done. Returned value was: None
What is this “LazySelectSequence([1 item])” , and why is this coming out in the logs, is there a way to get the actual value?
This is the link to the lab:
WEEK4-AIRFLOW_BEST_PRACTICE_LAB