You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by am...@apache.org on 2025/08/20 12:30:31 UTC
(airflow) branch v3-0-test updated: [v3-0-test] Fix flaky timeout test by using relative start_time calculation (#54641) (#54699)
This is an automated email from the ASF dual-hosted git repository.
amoghdesai pushed a commit to branch v3-0-test
in repository https://gitbox.apache.org/repos/asf/airflow.git
The following commit(s) were added to refs/heads/v3-0-test by this push:
new 85bc0c55683 [v3-0-test] Fix flaky timeout test by using relative start_time calculation (#54641) (#54699)
85bc0c55683 is described below
commit 85bc0c55683309ac49bbe46114cbc745772bccf9
Author: Amogh Desai <am...@gmail.com>
AuthorDate: Wed Aug 20 18:00:25 2025 +0530
[v3-0-test] Fix flaky timeout test by using relative start_time calculation (#54641) (#54699)
---
airflow-core/tests/unit/dag_processing/test_manager.py | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/airflow-core/tests/unit/dag_processing/test_manager.py b/airflow-core/tests/unit/dag_processing/test_manager.py
index cbd13f4aaa3..0d48f7b1626 100644
--- a/airflow-core/tests/unit/dag_processing/test_manager.py
+++ b/airflow-core/tests/unit/dag_processing/test_manager.py
@@ -520,7 +520,9 @@ class TestDagFileProcessorManager:
def test_kill_timed_out_processors_kill(self):
manager = DagFileProcessorManager(max_runs=1, processor_timeout=5)
- processor, _ = self.mock_processor(start_time=16000)
+ # Set start_time to ensure timeout occurs: start_time = current_time - (timeout + 1) = always (timeout + 1) seconds
+ start_time = time.monotonic() - manager.processor_timeout - 1
+ processor, _ = self.mock_processor(start_time=start_time)
manager._processors = {
DagFileInfo(
bundle_name="testing", rel_path=Path("abc.txt"), bundle_path=TEST_DAGS_FOLDER