Skip to content

Remove regexp from dag.partial_subset method and update callers#47360

Merged
potiuk merged 3 commits intoapache:mainfrom
bugraoz93:feat/46971/remove-regexp-from-partial-subset
Mar 7, 2025
Merged

Remove regexp from dag.partial_subset method and update callers#47360
potiuk merged 3 commits intoapache:mainfrom
bugraoz93:feat/46971/remove-regexp-from-partial-subset

Conversation

@bugraoz93
Copy link
Contributor

@bugraoz93 bugraoz93 commented Mar 4, 2025

closes: #46971
After thread discussions and discussions in the dev meeting. I updated the regexp usage on the API side. I searched and have never found a place in Airflow where the method partial_subset is called with regexp. So updating it hasn't impacted too many places.

Follow-up: Enhance API request validation to catch any regexp usage for str fields and return errors independent from the endpoint. This will enhance and cover all API request #47364


^ 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.

Copy link
Member

@pierrejeambrun pierrejeambrun left a comment

Choose a reason for hiding this comment

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

A few nits

@bugraoz93
Copy link
Contributor Author

A few nits

Thank you, Pierre, for your review! I will address your comments shortly.

@bugraoz93 bugraoz93 force-pushed the feat/46971/remove-regexp-from-partial-subset branch from 799813b to c747407 Compare March 5, 2025 21:53
Copy link
Member

@pierrejeambrun pierrejeambrun left a comment

Choose a reason for hiding this comment

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

I think the unnecessary str cast remains, it got omitted in c747407 otherwise LGTM.

@bugraoz93
Copy link
Contributor Author

I think the unnecessary str cast remains, it got omitted in c747407 otherwise LGTM.

Thanks for the review! My bad! Haven't realised it stayed. I assumed it was gone and resolved the thread. I will delete that in the coming hours

@bugraoz93 bugraoz93 force-pushed the feat/46971/remove-regexp-from-partial-subset branch from c747407 to 3d2d9e9 Compare March 7, 2025 00:08
@potiuk potiuk merged commit 85c3fba into apache:main Mar 7, 2025
89 checks passed
potiuk added a commit to potiuk/airflow that referenced this pull request Mar 7, 2025
Following discusison in https://lists.apache.org/thread/nnttnblj3tcv2wqj79gwovtfhgq8lvmm
and PR merged apache#47360 and
opened issue apache#47364 ideal that could
prevent new additions of regexp to UI. I think it's time to remove
google-re2.
potiuk added a commit to potiuk/airflow that referenced this pull request Mar 7, 2025
Following discusison in https://lists.apache.org/thread/nnttnblj3tcv2wqj79gwovtfhgq8lvmm
and PR merged apache#47360 and
opened issue apache#47364 ideal that could
prevent new additions of regexp to UI. I think it's time to remove
google-re2.
potiuk added a commit that referenced this pull request Mar 7, 2025
Following discusison in https://lists.apache.org/thread/nnttnblj3tcv2wqj79gwovtfhgq8lvmm
and PR merged #47360 and
opened issue #47364 ideal that could
prevent new additions of regexp to UI. I think it's time to remove
google-re2.
nailo2c pushed a commit to nailo2c/airflow that referenced this pull request Apr 4, 2025
…he#47360)

* Remove regexp from dag.partial_subset method and update callers

* Remove casting and convert list checking to old method

* Remove not needed casting
nailo2c pushed a commit to nailo2c/airflow that referenced this pull request Apr 4, 2025
Following discusison in https://lists.apache.org/thread/nnttnblj3tcv2wqj79gwovtfhgq8lvmm
and PR merged apache#47360 and
opened issue apache#47364 ideal that could
prevent new additions of regexp to UI. I think it's time to remove
google-re2.
kosteev pushed a commit to GoogleCloudPlatform/composer-airflow that referenced this pull request May 28, 2025
Following discusison in https://lists.apache.org/thread/nnttnblj3tcv2wqj79gwovtfhgq8lvmm
and PR merged apache/airflow#47360 and
opened issue apache/airflow#47364 ideal that could
prevent new additions of regexp to UI. I think it's time to remove
google-re2.

GitOrigin-RevId: 092cc57f0257c55bfa4e7db9aa91d9c2525bca41
kosteev pushed a commit to GoogleCloudPlatform/composer-airflow that referenced this pull request Sep 24, 2025
Following discusison in https://lists.apache.org/thread/nnttnblj3tcv2wqj79gwovtfhgq8lvmm
and PR merged apache/airflow#47360 and
opened issue apache/airflow#47364 ideal that could
prevent new additions of regexp to UI. I think it's time to remove
google-re2.

GitOrigin-RevId: 092cc57f0257c55bfa4e7db9aa91d9c2525bca41
kosteev pushed a commit to GoogleCloudPlatform/composer-airflow that referenced this pull request Oct 21, 2025
Following discusison in https://lists.apache.org/thread/nnttnblj3tcv2wqj79gwovtfhgq8lvmm
and PR merged apache/airflow#47360 and
opened issue apache/airflow#47364 ideal that could
prevent new additions of regexp to UI. I think it's time to remove
google-re2.

GitOrigin-RevId: 092cc57f0257c55bfa4e7db9aa91d9c2525bca41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Eliminate Regexp Usage in API for root Parameter and task_ids_or_regex

3 participants