-
Notifications
You must be signed in to change notification settings - Fork 6.5k
fix(samples): fix column name in DagModel of Airflow workflow to clean up database #6532
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
fix(samples): fix column name in DagModel of Airflow workflow to clean up database #6532
Conversation
(edited) - I see in the issue comment this only affects Airflow 2+. Thanks for the fix! |
Hey @kosteev - I now see tests aren't passing. Are they passing for you locally? (See the Testing Guidelines for instructions on running tests locally) |
@leahecole I've bumped version of apache-airflow in requirements.txt file. I wasn't able to run locally tests with nox, but I have installed pypi requirements* manually and ran py.test manually, and airflow_db_cleanup_test has passed successfully. Can you, please trigger Kokoro. I believe it has to be triggered manually, as I do not see it is executed automatically. |
I see it failed again. Trying actually to run all tests locally and fix. |
…docs-samples into db-clean-up-airflow2-fix
Ok. I have updated constraints.txt file to have constraints (I didn't realized we have it) to Airflow 2.1.2 constraints (as I bumped it in requirements.txt) and it was the reason for failing tests with new Airflow version. Now hadoop_tutorial_test.test_dag_import passes for me locally. Please, run Kokoro again. |
Side question: can I get permissions for running Kokoro CI tests for this specific folder? |
…docs-samples into db-clean-up-airflow2-fix
New DataflowTemplatedJobStartOperator requires |
ready for review 2 when you are @dandhlee 😄 |
@@ -130,7 +130,7 @@ | |||
"keep_last_group_by": None | |||
}, { | |||
"airflow_db_model": DagModel, | |||
"age_check_column": DagModel.last_scheduler_run, | |||
"age_check_column": DagModel.last_parsed_time, # prior to Airflow 2.0.2 this column was named last_scheduler_run |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1 for mentioning this!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Description
Fixes #6531
Checklist
nox -s py-3.6
(see Test Environment Setup)nox -s lint
(see Test Environment Setup)