Skip to content

Fix connection port field validation (#68382)#69130

Closed
Alwaysgaurav1 wants to merge 6 commits into
apache:mainfrom
Alwaysgaurav1:fix/68382-connection-port-validation
Closed

Fix connection port field validation (#68382)#69130
Alwaysgaurav1 wants to merge 6 commits into
apache:mainfrom
Alwaysgaurav1:fix/68382-connection-port-validation

Conversation

@Alwaysgaurav1

@Alwaysgaurav1 Alwaysgaurav1 commented Jun 29, 2026

Copy link
Copy Markdown

This PR implements error propagation for variable write (set) and delete (delete) operations inside the Task SDK. Previously, if the API server rejected these operations, the returned ErrorResponse was ignored by the task runner, causing the task to report success despite a backend failure.

closes: #68537


Was generative AI tooling used to co-author this PR?
  • Yes (please specify the tool below)

Antigravity (Gemini 3.5 Flash)

Generated-by: Antigravity (Gemini 3.5 Flash) following the guidelines

@boring-cyborg

boring-cyborg Bot commented Jun 29, 2026

Copy link
Copy Markdown

Congratulations on your first Pull Request and welcome to the Apache Airflow community! If you have any issues or are unsure about any anything please check our Contributors' Guide
Here are some useful points:

  • Pay attention to the quality of your code (ruff, mypy and type annotations). Our prek-hooks will help you with that.
  • In case of a new feature add useful documentation (in docstrings or in docs/ directory). Adding a new operator? Check this short guide Consider adding an example Dag that shows how users should use it.
  • Consider using Breeze environment for testing locally, it's a heavy docker but it ships with a working Airflow and a lot of integrations.
  • Be patient and persistent. It might take some time to get a review or get the final approval from Committers.
  • Please follow ASF Code of Conduct for all communication including (but not limited to) comments on Pull Requests, Mailing list and Slack.
  • Be sure to read the Airflow Coding style.
  • Always keep your Pull Requests rebased, otherwise your build might fail due to changes not related to your commits.
    Apache Airflow is a community-driven project and together we are making it better 🚀.
    In case of doubts contact the developers at:
    Mailing List: dev@airflow.apache.org
    Slack: https://s.apache.org/airflow-slack

@Alwaysgaurav1

Copy link
Copy Markdown
Author

Hi maintainers! 👋 This is my first contribution to Apache Airflow. Could someone please approve the CI workflow runs so the tests can execute?

Also tagging @ashb since you commented on the original issue #68382 with guidance on the port validation approach. This PR implements validation (1-65535) across all entry points: core model, REST API, Task SDK, connection test model, and CLI — with a shared validate_port() helper and 19 test cases.

Thank you! 🙏

@Alwaysgaurav1 Alwaysgaurav1 requested a review from henry3260 as a code owner July 3, 2026 07:02
@Alwaysgaurav1 Alwaysgaurav1 force-pushed the fix/68382-connection-port-validation branch from 4412d09 to cfa768b Compare July 6, 2026 05:44

@pierrejeambrun pierrejeambrun 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.

Thanks @Alwaysgaurav1 for the PR.

Unfortunately there is already #68777 opened for this and closer to being merged.

Closing in favor of it you can take a look at the reviews there a bunch also applies for yours.

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.

Task SDK: Variable.set/delete swallow API errors — a rejected write does not fail the task

3 participants