Skip to content

Create a more efficient airflow dag test command that also has better local logging#26400

Merged
dimberman merged 42 commits into
apache:mainfrom
astronomer:improved-local-dag-test
Sep 22, 2022
Merged

Create a more efficient airflow dag test command that also has better local logging#26400
dimberman merged 42 commits into
apache:mainfrom
astronomer:improved-local-dag-test

Conversation

@dimberman

@dimberman dimberman commented Sep 14, 2022

Copy link
Copy Markdown
Contributor

The current airflow dag test command is insufficient for an iterative local workflow when developing dags. The current system relies on running a backfill job which a) is extremely slow and b) only shows scheduler-level logs, so the user would need to search for log files to see how their tasks actually ran!

This new system

Speed

With this new system, we see a notable speedup in between-task speed. The new airflow dag test command can load tasks immediately and not wait for a scheduler heartbeat or other irrelevant airflow processes.

Before:

example bash operator: 13 seconds
example python operator: 26 seconds

After

example bash operator: 6 seconds
example python operator: 16 seconds

Logging

Previously, the airflow dag test command would pass on scheduler-level logs. This gives essentially 0 useful information for a DAG writer, and would force them to seek out task.log files in their filesystem every time they run a test dag. To improve this, we now surface task-level logs to the command line. We also no longer have any scheduler-level logs as we are no longer using a scheduler!

Before

[2022-09-14 14:37:48,310] {dagbag.py:522} INFO - Filling up the DagBag from /files/dags
[2022-09-14 14:37:48,967] {base_executor.py:93} INFO - Adding to queue: ['<TaskInstance: example_bash_operator.runme_0 backfill__2022-01-02T00:00:00+00:00 [queued]>']
[2022-09-14 14:37:48,973] {base_executor.py:93} INFO - Adding to queue: ['<TaskInstance: example_bash_operator.runme_1 backfill__2022-01-02T00:00:00+00:00 [queued]>']
[2022-09-14 14:37:48,979] {base_executor.py:93} INFO - Adding to queue: ['<TaskInstance: example_bash_operator.runme_2 backfill__2022-01-02T00:00:00+00:00 [queued]>']
[2022-09-14 14:37:48,985] {base_executor.py:93} INFO - Adding to queue: ['<TaskInstance: example_bash_operator.also_run_this backfill__2022-01-02T00:00:00+00:00 [queued]>']
[2022-09-14 14:37:48,991] {base_executor.py:93} INFO - Adding to queue: ['<TaskInstance: example_bash_operator.this_will_skip backfill__2022-01-02T00:00:00+00:00 [queued]>']
[2022-09-14 14:37:54,045] {subprocess.py:62} INFO - Tmp dir root location:
 /tmp
[2022-09-14 14:37:54,045] {subprocess.py:74} INFO - Running command: ['/bin/bash', '-c', 'echo "example_bash_operator__runme_0__20220102" && sleep 1']
[2022-09-14 14:37:54,053] {subprocess.py:85} INFO - Output:
[2022-09-14 14:37:54,055] {subprocess.py:92} INFO - example_bash_operator__runme_0__20220102
[2022-09-14 14:37:55,061] {subprocess.py:96} INFO - Command exited with return code 0
[2022-09-14 14:37:55,117] {subprocess.py:62} INFO - Tmp dir root location:
 /tmp
[2022-09-14 14:37:55,117] {subprocess.py:74} INFO - Running command: ['/bin/bash', '-c', 'echo "example_bash_operator__runme_1__20220102" && sleep 1']
[2022-09-14 14:37:55,124] {subprocess.py:85} INFO - Output:
[2022-09-14 14:37:55,125] {subprocess.py:92} INFO - example_bash_operator__runme_1__20220102
[2022-09-14 14:37:56,131] {subprocess.py:96} INFO - Command exited with return code 0
[2022-09-14 14:37:56,186] {subprocess.py:62} INFO - Tmp dir root location:
 /tmp
[2022-09-14 14:37:56,186] {subprocess.py:74} INFO - Running command: ['/bin/bash', '-c', 'echo "example_bash_operator__runme_2__20220102" && sleep 1']
[2022-09-14 14:37:56,193] {subprocess.py:85} INFO - Output:
[2022-09-14 14:37:56,194] {subprocess.py:92} INFO - example_bash_operator__runme_2__20220102
[2022-09-14 14:37:57,199] {subprocess.py:96} INFO - Command exited with return code 0
[2022-09-14 14:37:57,257] {subprocess.py:62} INFO - Tmp dir root location:
 /tmp
[2022-09-14 14:37:57,257] {subprocess.py:74} INFO - Running command: ['/bin/bash', '-c', 'echo "ti_key=example_bash_operator__also_run_this__20220102"']
[2022-09-14 14:37:57,265] {subprocess.py:85} INFO - Output:
[2022-09-14 14:37:57,266] {subprocess.py:92} INFO - ti_key=example_bash_operator__also_run_this__20220102
[2022-09-14 14:37:57,266] {subprocess.py:96} INFO - Command exited with return code 0
[2022-09-14 14:37:57,307] {subprocess.py:62} INFO - Tmp dir root location:
 /tmp
[2022-09-14 14:37:57,308] {subprocess.py:74} INFO - Running command: ['/bin/bash', '-c', 'echo "hello world"; exit 99;']
[2022-09-14 14:37:57,316] {subprocess.py:85} INFO - Output:
[2022-09-14 14:37:57,317] {subprocess.py:92} INFO - hello world
[2022-09-14 14:37:57,317] {subprocess.py:96} INFO - Command exited with return code 99
[2022-09-14 14:37:57,340] {backfill_job.py:381} INFO - [backfill progress] | finished run 0 of 1 | tasks waiting: 2 | succeeded: 4 | running: 0 | failed: 0 | skipped: 1 | deadlocked: 0 | not ready: 2
[2022-09-14 14:37:57,351] {base_executor.py:93} INFO - Adding to queue: ['<TaskInstance: example_bash_operator.run_after_loop backfill__2022-01-02T00:00:00+00:00 [queued]>']
[2022-09-14 14:37:58,918] {subprocess.py:62} INFO - Tmp dir root location:
 /tmp
[2022-09-14 14:37:58,918] {subprocess.py:74} INFO - Running command: ['/bin/bash', '-c', 'echo 1']
[2022-09-14 14:37:58,925] {subprocess.py:85} INFO - Output:
[2022-09-14 14:37:58,926] {subprocess.py:92} INFO - 1
[2022-09-14 14:37:58,927] {subprocess.py:96} INFO - Command exited with return code 0
[2022-09-14 14:37:58,945] {dagrun.py:595} INFO - Marking run <DagRun example_bash_operator @ 2022-01-02T00:00:00+00:00: backfill__2022-01-02T00:00:00+00:00, state:running, queued_at: None. externally triggered: False> successful
[2022-09-14 14:37:58,946] {dagrun.py:657} INFO - DagRun Finished: dag_id=example_bash_operator, execution_date=2022-01-02T00:00:00+00:00, run_id=backfill__2022-01-02T00:00:00+00:00, run_start_date=2022-09-14 14:37:48.865989+00:00, run_end_date=2022-09-14 14:37:58.946180+00:00, run_duration=10.080191, state=success, external_trigger=False, run_type=backfill, data_interval_start=2022-01-02T00:00:00+00:00, data_interval_end=2022-01-03T00:00:00+00:00, dag_hash=None
[2022-09-14 14:37:58,946] {backfill_job.py:381} INFO - [backfill progress] | finished run 1 of 1 | tasks waiting: 0 | succeeded: 5 | running: 0 | failed: 0 | skipped: 2 | deadlocked: 0 | not ready: 0
[2022-09-14 14:37:58,949] {backfill_job.py:875} INFO - Backfill done for DAG <DAG: example_bash_operator>. Exiting.

After:

root@613d334d9c9d:/opt/airflow# airflow dags test example_bash_operator  2022-01-03
[2022-09-14 14:43:45,232] {dagbag.py:522} INFO - Filling up the DagBag from /files/dags
[2022-09-14 14:43:45,997] {dag_command.py:556} INFO - dagrun id:example_bash_operator
/opt/airflow/airflow/cli/commands/dag_command.py:573 RemovedInAirflow3Warning: Calling `DAG.create_dagrun()` without an explicit data interval is deprecated
created dagrun <DagRun example_bash_operator @ 2022-01-03T00:00:00+00:00: manual__2022-01-03T00:00:00+00:00, state:running, queued_at: None. externally triggered: False>
[2022-09-14 14:43:46,013] {dag_command.py:496} INFO - starting dagrun
[2022-09-14 14:43:46,138] {dag_command.py:542} INFO - *****************************************************
[2022-09-14 14:43:46,138] {dag_command.py:543} INFO - Running task runme_0
[2022-09-14 14:43:46,144] {subprocess.py:62} INFO - Tmp dir root location:
 /tmp
[2022-09-14 14:43:46,145] {subprocess.py:74} INFO - Running command: ['/bin/bash', '-c', 'echo "example_bash_operator__runme_0__20220103" && sleep 1']
[2022-09-14 14:43:46,152] {subprocess.py:85} INFO - Output:
[2022-09-14 14:43:46,154] {subprocess.py:92} INFO - example_bash_operator__runme_0__20220103
[2022-09-14 14:43:47,158] {subprocess.py:96} INFO - Command exited with return code 0
[2022-09-14 14:43:47,179] {dag_command.py:547} INFO - runme_0 ran successfully!
[2022-09-14 14:43:47,180] {dag_command.py:550} INFO - *****************************************************
[2022-09-14 14:43:47,197] {dag_command.py:542} INFO - *****************************************************
[2022-09-14 14:43:47,197] {dag_command.py:543} INFO - Running task runme_1
[2022-09-14 14:43:47,203] {subprocess.py:62} INFO - Tmp dir root location:
 /tmp
[2022-09-14 14:43:47,204] {subprocess.py:74} INFO - Running command: ['/bin/bash', '-c', 'echo "example_bash_operator__runme_1__20220103" && sleep 1']
[2022-09-14 14:43:47,211] {subprocess.py:85} INFO - Output:
[2022-09-14 14:43:47,213] {subprocess.py:92} INFO - example_bash_operator__runme_1__20220103
[2022-09-14 14:43:48,219] {subprocess.py:96} INFO - Command exited with return code 0
[2022-09-14 14:43:48,239] {dag_command.py:547} INFO - runme_1 ran successfully!
[2022-09-14 14:43:48,239] {dag_command.py:550} INFO - *****************************************************
[2022-09-14 14:43:48,253] {dag_command.py:542} INFO - *****************************************************
[2022-09-14 14:43:48,253] {dag_command.py:543} INFO - Running task runme_2
[2022-09-14 14:43:48,259] {subprocess.py:62} INFO - Tmp dir root location:
 /tmp
[2022-09-14 14:43:48,259] {subprocess.py:74} INFO - Running command: ['/bin/bash', '-c', 'echo "example_bash_operator__runme_2__20220103" && sleep 1']
[2022-09-14 14:43:48,266] {subprocess.py:85} INFO - Output:
[2022-09-14 14:43:48,267] {subprocess.py:92} INFO - example_bash_operator__runme_2__20220103
[2022-09-14 14:43:49,273] {subprocess.py:96} INFO - Command exited with return code 0
[2022-09-14 14:43:49,294] {dag_command.py:547} INFO - runme_2 ran successfully!
[2022-09-14 14:43:49,295] {dag_command.py:550} INFO - *****************************************************
[2022-09-14 14:43:49,374] {dag_command.py:542} INFO - *****************************************************
[2022-09-14 14:43:49,374] {dag_command.py:543} INFO - Running task also_run_this
[2022-09-14 14:43:49,380] {subprocess.py:62} INFO - Tmp dir root location:
 /tmp
[2022-09-14 14:43:49,380] {subprocess.py:74} INFO - Running command: ['/bin/bash', '-c', 'echo "ti_key=example_bash_operator__also_run_this__20220103"']
[2022-09-14 14:43:49,389] {subprocess.py:85} INFO - Output:
[2022-09-14 14:43:49,390] {subprocess.py:92} INFO - ti_key=example_bash_operator__also_run_this__20220103
[2022-09-14 14:43:49,390] {subprocess.py:96} INFO - Command exited with return code 0
[2022-09-14 14:43:49,395] {dag_command.py:547} INFO - also_run_this ran successfully!
[2022-09-14 14:43:49,395] {dag_command.py:550} INFO - *****************************************************
[2022-09-14 14:43:49,406] {dag_command.py:542} INFO - *****************************************************
[2022-09-14 14:43:49,407] {dag_command.py:543} INFO - Running task this_will_skip
[2022-09-14 14:43:49,412] {subprocess.py:62} INFO - Tmp dir root location:
 /tmp
[2022-09-14 14:43:49,413] {subprocess.py:74} INFO - Running command: ['/bin/bash', '-c', 'echo "hello world"; exit 99;']
[2022-09-14 14:43:49,420] {subprocess.py:85} INFO - Output:
[2022-09-14 14:43:49,421] {subprocess.py:92} INFO - hello world
[2022-09-14 14:43:49,422] {subprocess.py:96} INFO - Command exited with return code 99
[2022-09-14 14:43:49,422] {dag_command.py:549} INFO - Task Skipped, continuing
[2022-09-14 14:43:49,422] {dag_command.py:550} INFO - *****************************************************
[2022-09-14 14:43:49,440] {dag_command.py:542} INFO - *****************************************************
[2022-09-14 14:43:49,440] {dag_command.py:543} INFO - Running task run_after_loop
[2022-09-14 14:43:49,445] {subprocess.py:62} INFO - Tmp dir root location:
 /tmp
[2022-09-14 14:43:49,446] {subprocess.py:74} INFO - Running command: ['/bin/bash', '-c', 'echo 1']
[2022-09-14 14:43:49,453] {subprocess.py:85} INFO - Output:
[2022-09-14 14:43:49,454] {subprocess.py:92} INFO - 1
[2022-09-14 14:43:49,454] {subprocess.py:96} INFO - Command exited with return code 0
[2022-09-14 14:43:49,458] {dag_command.py:547} INFO - run_after_loop ran successfully!
[2022-09-14 14:43:49,458] {dag_command.py:550} INFO - *****************************************************
[2022-09-14 14:43:49,471] {dag_command.py:542} INFO - *****************************************************
[2022-09-14 14:43:49,471] {dag_command.py:543} INFO - Running task run_this_last
[2022-09-14 14:43:49,475] {dag_command.py:547} INFO - run_this_last ran successfully!
[2022-09-14 14:43:49,475] {dag_command.py:550} INFO - *****************************************************
[2022-09-14 14:43:49,480] {dagrun.py:595} INFO - Marking run <DagRun example_bash_operator @ 2022-01-03T00:00:00+00:00: manual__2022-01-03T00:00:00+00:00, state:running, queued_at: None. externally triggered: False> successful
[2022-09-14 14:43:49,480] {dagrun.py:657} INFO - DagRun Finished: dag_id=example_bash_operator, execution_date=2022-01-03T00:00:00+00:00, run_id=manual__2022-01-03T00:00:00+00:00, run_start_date=2022-01-03T00:00:00+00:00, run_end_date=2022-09-14 14:43:49.480895+00:00, run_duration=21998629.480895, state=success, external_trigger=False, run_type=manual, data_interval_start=2022-01-03T00:00:00+00:00, data_interval_end=2022-01-04T00:00:00+00:00, dag_hash=None

^ Add meaningful description above

Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in newsfragments.

@dimberman
dimberman requested review from ashb, dstandish and uranusjr and removed request for dstandish and uranusjr September 14, 2022 17:32
@dimberman
dimberman marked this pull request as ready for review September 14, 2022 17:35
@potiuk

potiuk commented Sep 14, 2022

Copy link
Copy Markdown
Member

This looks sooooper cool :). I will do some quick testing to see the experience.

One suggestions (asking more what you think about it and maybe those could be separate PRs., or maybe we could incorporate it in this one).

How about adding integration with pudb https://github.com/inducer/pudb - this is a very nice, console debugger with capabilities equal to those that modern IDE debuggers have (colored output/code syntax/breakpoints/watches/capability of opening iPython console at any moment and use repl to try/test anything. I'v heard very good things about pudb and I thought that we should integrate it better into Breeze experience, but I think, since our DAGs are Python, it would be perfect to add it here.

I imagine just adding --debug flag and automatically stopping at the first task of a DAG or smth.

WDYT @dimberman ?

@dimberman
dimberman force-pushed the improved-local-dag-test branch from e295ce7 to f2df9cf Compare September 14, 2022 18:40
@jedcunningham
jedcunningham self-requested a review September 14, 2022 18:43
Comment thread airflow/cli/commands/dag_command.py Outdated
Comment thread airflow/cli/commands/dag_command.py Outdated
Comment thread airflow/cli/commands/dag_command.py Outdated
Comment thread airflow/cli/commands/dag_command.py Outdated
log.info("*****************************************************")
log.info("Running task %s", current_task.task_id)
try:
xcom_value = current_task.execute(context=ti.get_template_context())

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
xcom_value = current_task.execute(context=ti.get_template_context())
xcom_value = ti.task.execute(context=ti.get_template_context(session=session))

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You also aren't calling pre_execute or post_execute here, so some operators might not work.

You probaly want to call a method on TI instead.

Possible ti._run_raw_task(session=session, test_mode=True)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ashb I agree on using the _run_raw_task function, but ironically the test_mode might not be the best idea here. test_mode prevents us from recording passing/failure in the database, and without that state we won't know when to run downstream tasks.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's not quite what test mode does.

It simply doesn't a session.commit(). But if you put a session.flush() after it (and are careful about transactions/passing session everywhere) then you can run all tasks in a single transaction, never commit it, and roll it back at the end.

I just tested this change and it works for downstream. See the video below.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ashb when I run this with test mode it seems to infinite loop as the tasks are never marked as finished?

@dimberman

Copy link
Copy Markdown
Contributor Author

Thank you @potiuk !

Do you think that would be too oppinionated to choose a specific debugger? One really awesome thing we could potentially do with this is even write a guide to use this in pycharm and vscode (since there's no parallelism it shouldn't be hard)

@ashb

ashb commented Sep 14, 2022

Copy link
Copy Markdown
Member

I don't think we should integrate any specific debugger here in this CLI function, but instruct people to use breakpoint() and then either it "just works" with their IDE's integrated debugger, or you can set PYTHONBREAKPOINT="pudb.set_trace" (for example) to change what debugger is used.

@potiuk

potiuk commented Sep 14, 2022

Copy link
Copy Markdown
Member

Thank you @potiuk !

Do you think that would be too oppinionated to choose a specific debugger? One really awesome thing we could potentially do with this is even write a guide to use this in pycharm and vscode (since there's no parallelism it shouldn't be hard)

I think not - especially that it is console textui/console only . I honestly don't care what the debugger is, I want this to run effortlessly. If we can make this works out-of-the-box without any manual setup, I would be all for it.

The problem with vscode/Pycharm is that it is not at all straightforward to integrate with "airflow dag test" command. Have you tried to add debug mode for any "airflow" command in either of them, this is a lot of hassle. First of all - it will not work when you have remote /shell access easily. Secondly, you cannot easily turn "airflow" command iine into a debuggable run. You need to create a custom configuraiton first, then have a local venv configured with the right version of airlfow installed and configured in the IDE, third you need to do "run -> create debug configuration" then you have to choose "module" then choose airflow module, then type extra parameters to pass. That's a lot of keystrokes and knowledge what to do. AND you have to heave your IDE installed in the place where you have your Airlfow installed. This might be acceptable for Breeze/Airflow development, but not at all acceptable for DAG development.

Using "opinionated debugger" with console interface is so much less friction.

just 'airflow dag test test" and add --debug . That's it. You can still do the above with any IDE you have. This will not block you - but this one will enable running visual debuggging even if you just logged in remotely with SSH to Airlfow installation.

Let me reverse the question:

What is the problem you foresee by having an opinionated predefined flag when it does not close any of the other options?

@potiuk

potiuk commented Sep 14, 2022

Copy link
Copy Markdown
Member

We can even do not make it a requiremeent, but install it dynamically when someone uses --debug option BTW.

@potiuk

potiuk commented Sep 14, 2022

Copy link
Copy Markdown
Member

Or name it --debug-pudb as a flag.

@ashb

ashb commented Sep 14, 2022

Copy link
Copy Markdown
Member

It needs a bit of work/polish, but using this

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Airflow: Dag in current file",
            "type": "python",
            "request": "launch",
            "program": "${file}",
            "args": ["dags", "test"],
            "console": "integratedTerminal",
            "justMyCode": true
        }
    ]
}

That gives me something I can run against a dag file. To make that work I did add this to the dag file (and a couple of other local changes to make this work for dags test command:

if __name__ == "__main__":
    dag.cli()

Edit: THis works from VScode running on windows against an airflow in WSL2.

@ashb

ashb commented Sep 14, 2022

Copy link
Copy Markdown
Member

Sneak peak

2022-09-14.20-34-13.webm

@potiuk

potiuk commented Sep 14, 2022

Copy link
Copy Markdown
Member

Sneak peak

2022-09-14.20-34-13.webm

We already have DebugExecutor that does exactly that in the same way and a bit simpler (and is portable across IDEs) I think.. https://airflow.apache.org/docs/apache-airflow/stable/executor/debug.html?highlight=debug+executor

I was telling about debugging without having any IDE setup.

Comment thread airflow/models/dag.py
Comment thread airflow/models/dag.py Outdated
Comment thread airflow/models/dag.py
Comment on lines +3610 to +3617
dr: DagRun = (
session.query(DagRun)
.filter(DagRun.dag_id == dag.dag_id, DagRun.execution_date == execution_date)
.first()
)
if dr:
session.delete(dr)
session.commit()

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It might make sense to create _delete_dagrun for that. Mainly because of the low-level session calls imo. WDYT?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we foresee other use-cases to delete dagruns? FWIW I believe @ashb plans to look into a way for us to do this without ever actually touching the DB which would make this irrelevant in the long run.

Comment thread airflow/models/dag.py Outdated
Comment thread docs/apache-airflow/executor/debug.rst Outdated
Comment thread docs/apache-airflow/executor/debug.rst Outdated
Comment thread docs/apache-airflow/executor/debug.rst Outdated
Comment thread docs/apache-airflow/executor/debug.rst Outdated
Comment thread docs/apache-airflow/executor/debug.rst Outdated
Comment thread docs/apache-airflow/executor/debug.rst Outdated
Comment thread newsfragments/26400.significant.rst Outdated
Comment thread tests/models/test_dag.py
dimberman and others added 5 commits September 21, 2022 07:43
Co-authored-by: Felix Uellendall <feluelle@users.noreply.github.com>
Co-authored-by: Felix Uellendall <feluelle@users.noreply.github.com>

@feluelle feluelle left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dimberman
dimberman merged commit 71c64de into apache:main Sep 22, 2022
@dimberman
dimberman deleted the improved-local-dag-test branch September 22, 2022 16:14

Debug Executor
==================
Debug Executor (deprecated)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this mean we want to remove DebugExecutor in Airflow 3?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 to @eladkal question.
I stumbled across this while working on something entirely different. I'm very curious to have this discussion as well.

Currently AIP-47 system tests depend on the DebugExecutor:

The tests should be structured in the way that they are easy to run as “standalone” tests manually but they should also nicely be integrated into pytest test execution environment. This can be achieved by leveraging the DebugExecutor and utilising modern pytest test discovery mechanism

So we'd need to do some migration there if we were to deprecate this executor (CC @potiuk @mnojek). I know @bhirsz has mentioned before they're using a different executor altogether for their system tests, maybe that's a more viable option.

We should also add deprecation warnings if we plan to deprecate this executor.

o-nikolas added a commit to aws-mwaa/upstream-to-airflow that referenced this pull request Oct 21, 2022
Cleanup the docstrings which were still mentioning the usage of the
DebugExecutor
potiuk pushed a commit that referenced this pull request Oct 28, 2022
Cleanup the docstrings which were still mentioning the usage of the
DebugExecutor
@ephraimbuddy ephraimbuddy added the type:new-feature Changelog: New Features label Nov 16, 2022
@ephraimbuddy ephraimbuddy added this to the Airflow 2.5.0 milestone Nov 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:CLI type:new-feature Changelog: New Features

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants