Граф коммитов

17 Коммитов

Автор SHA1 Сообщение Дата
Kaxil Naik 7c6dfcb0bf
Use unittest.mock instead of backported mock library (#11643)
mock is now part of the Python standard library, available as unittest.mock in Python 3.3 onwards.
2020-10-22 13:23:15 +01:00
Ash Berlin-Taylor 8ac90b0c4f
[AIRFLOW-5615] Reduce duplicated logic around job heartbeating (#6311)
Both SchedulerJob and LocalTaskJob have their own timers and decide when
to call heartbeat based upon that. This makes those functions harder to
follow, (and the logs more confusing) so I've moved the logic to BaseJob
2020-05-27 12:18:30 +01:00
Ash Berlin-Taylor c3af681edf
Convert tests/jobs/test_base_job.py to pytest (#8856)
I would like to (create) and use a pytest fixture as a parameter, but
they cannot be used on unittest.TestCase functions:

> unittest.TestCase methods cannot directly receive fixture arguments as
> implementing that is likely to inflict on the ability to run general
> unittest.TestCase test suites.
2020-05-13 14:00:46 +01:00
Kaxil Naik 0a7b5004ac
Fix displaying Executor Class Name in "Base Job" table (#8679) 2020-05-02 18:30:45 +01:00
Kaxil Naik 81f50a9f2e
[AIRFLOW-XXXX] Fix typo in tests/jobs/test_base_job.py (#7698) 2020-03-12 01:51:16 +00:00
Alex Guziel 008b4bab14
[AIRFLOW-6730] Use total_seconds instead of seconds (#7363)
* [AIRFLOW-6730] Use total_seconds instead of seconds

* adds tests and fixes types issue

* fix test
2020-02-27 17:46:49 -08:00
Tomek Urbaszek 311140616d
[AIRFLOW-6864] Make airfow/jobs pylint compatible (#7484)
fixup! [AIRFLOW-6864] Make airfow/jobs pylint compatible

fixup! fixup! [AIRFLOW-6864] Make airfow/jobs pylint compatible

fixup! [AIRFLOW-6864] Make airfow/jobs pylint compatible

fixup! [AIRFLOW-6864] Make airfow/jobs pylint compatible

fixup! [AIRFLOW-6864] Make airfow/jobs pylint compatible

fixup! [AIRFLOW-6864] Make airfow/jobs pylint compatible

fixup! [AIRFLOW-6864] Make airfow/jobs pylint compatible

fixup! [AIRFLOW-6864] Make airfow/jobs pylint compatible

fixup! [AIRFLOW-6864] Make airfow/jobs pylint compatible
2020-02-25 22:06:46 +01:00
Kamil Breguła 97a429f9d0
[AIRFLOW-6714] Remove magic comments about UTF-8 (#7338) 2020-02-02 22:18:19 +01:00
Tomek Urbaszek d2cbf92290
[AIRFLOW-6382] Extract provide/create session to session module (#6938)
Extracting provide_session and create_session to separate module
reduces number of cyclic imports and make a disctinction between
session and database
2019-12-28 20:31:07 +01:00
Tomek b31ce50f74 [AIRFLOW-6365] Remove tests/compat (#6919) 2019-12-27 09:14:02 +01:00
Tomek 6fffa5b0d7 [AIRFLOW-6343] Make tests/* pylint compatible (#6899) 2019-12-26 21:30:43 +01:00
Ash Berlin-Taylor 68b8ec5f41
[AIRFLOW-5102] Worker jobs should terminate themselves if they can't heartbeat (#6284)
If a LocalTaskJob fails to heartbeat for
scheduler_zombie_task_threshold, it should shut itself down.

However, at some point, a change was made to catch exceptions inside the
heartbeat, so the LocalTaskJob thought it had managed to heartbeat
successfully.

This effectively means that zombie tasks don't shut themselves down.
When the scheduler reschedules the job, this means we could have two
instances of the task running concurrently.
2019-10-08 17:00:15 +01:00
Kevin Yang d719e1fd67 [AIRFLOW-5362] Reorder imports (#5944) 2019-10-02 16:30:03 +01:00
Bas Harenslak 5196db38f2 [AIRFLOW-5241] Make all test class names consistent (#5847)
Make all test class names consistent by starting with Test
2019-08-22 14:14:25 +02:00
Ash Berlin-Taylor 6ae5f2b69a
[AIRFLOW-4864] Remove calls to load_test_config (#5502)
We already set the environment variable in the test runner so that
airflow.configuration will do this -- we don't need to do it again
2019-07-01 16:43:03 +01:00
Ash Berlin-Taylor 3dcfe2801c
[AIRFLOW-4343] Show warning in UI if scheduler is not running (#5127)
Now that the webserver is more stateless, if the scheduler is not
running the list of dags won't populate, making it harder for new
starters to work out what is going on.

New dep is BSD-2 which is Cat-A under ASF
2019-05-29 10:50:07 +01:00
Chao-Han Tsai d337c93c28 [AIRFLOW-4535] Break jobs.py into multiple files (#5303) 2019-05-19 20:43:54 +02:00