airflow icon indicating copy to clipboard operation
airflow copied to clipboard

URL contains tag query parameter but Airflow UI does not correctly visualize the tags

Open wolfier opened this issue 3 years ago • 1 comments

Apache Airflow version

2.3.3 (latest released)

What happened

An URL I saved in the past, https://astronomer.astronomer.run/dx4o2568/home?tags=test, has the tag field in the query parameter though I was not aware of this. When I clicked on the URL, I was confused because I did not see any DAGs when I should have a bunch.

After closer inspection, I realized that the URL has the tag field in the query parameter but then noticed that the tag box in the Airflow UI wasn't properly populated.

screen_shot_2022-07-12_at_8 11 07_am

What you think should happen instead

When I clicked on the URL, the tag box should have been populated with the strings in the URL.

How to reproduce

Start an Airflow deployment with some DAGs and add the tag query parameter. More specifically, it has to be a tag that is not used by any DAG.

Operating System

N/A

Versions of Apache Airflow Providers

No response

Deployment

Astronomer

Deployment details

No response

Anything else

No response

Are you willing to submit PR?

  • [X] Yes I am willing to submit a PR!

Code of Conduct

wolfier avatar Aug 03 '22 00:08 wolfier

So in the UI you're not able to put in an invalid tag, but a url could be wrong. The webserver should catch an invalid tag and remove it, listing all dags.

Around here we should check if the DagTags exists and remove any invalid ones.

Here is an example of how to redirect the page.

bbovenzi avatar Aug 10 '22 20:08 bbovenzi