This is an automated email from the ASF dual-hosted git repository. jhtimmins pushed a commit to branch v2-1-test in repository https://gitbox.apache.org/repos/asf/airflow.git
commit dcfc23ecd5fd8d175d9d46097f6f05ce46575a8a Author: Jarek Potiuk <ja...@potiuk.com> AuthorDate: Sat Aug 7 22:47:15 2021 +0200 Attempt to reduce flakiness of PythonVirtualeEnv test_airflow_context (#17486) We have a global limit (60 seconds) for individual test execution, however 'test_airflow_context' of the Python Virtualenv test might take longer in case they are run in parallel - because they are using dill serialization including a lot of serializable data from the context of the task. We give the test 120 seconds to complete now. (cherry picked from commit 793afaade115dccda7b544cfe8af756b88350abb) --- scripts/in_container/entrypoint_ci.sh | 2 ++ tests/operators/test_python.py | 3 +++ 2 files changed, 5 insertions(+) diff --git a/scripts/in_container/entrypoint_ci.sh b/scripts/in_container/entrypoint_ci.sh index 6ba7f6e..0c00163 100755 --- a/scripts/in_container/entrypoint_ci.sh +++ b/scripts/in_container/entrypoint_ci.sh @@ -216,6 +216,8 @@ EXTRA_PYTEST_ARGS=( "--pythonwarnings=ignore::PendingDeprecationWarning" "--junitxml=${RESULT_LOG_FILE}" # timeouts in seconds for individual tests + "--timeouts-order" + "moi" "--setup-timeout=20" "--execution-timeout=60" "--teardown-timeout=20" diff --git a/tests/operators/test_python.py b/tests/operators/test_python.py index 3b1ad92..fd7f259 100644 --- a/tests/operators/test_python.py +++ b/tests/operators/test_python.py @@ -921,6 +921,9 @@ class TestPythonVirtualenvOperator(unittest.TestCase): self._run_as_operator(f, templates_dict={'ds': '{{ ds }}'}) + # This tests might take longer than default 60 seconds as it is serializing a lot of + # context using dill (which is slow apparently). + @pytest.mark.execution_timeout(120) def test_airflow_context(self): def f( # basic