Skip to content

Add validation for missing host and cluster/workgroup identifier in aws iam token retrieval - #61965

Merged
potiuk merged 3 commits into
apache:mainfrom
justinpakzad:fix/postgres-hook-host-clusid-none-handling
Mar 12, 2026
Merged

Add validation for missing host and cluster/workgroup identifier in aws iam token retrieval#61965
potiuk merged 3 commits into
apache:mainfrom
justinpakzad:fix/postgres-hook-host-clusid-none-handling

Conversation

@justinpakzad

Copy link
Copy Markdown
Contributor

Added validation/handling in the PostgresHook get_aws_iam_token() method for situations where host and cluster-identifier/workgroup-name are not provided. Added additional test cases as well.

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

  • Read the Pull Request Guidelines for more information. Note: commit author/co-author name and email in commits become permanently public when merged.
  • For fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
  • When adding dependency, check compliance with the ASF 3rd Party License Policy.
  • For significant user-facing changes create newsfragment: {pr_number}.significant.rst or {issue_number}.significant.rst, in airflow-core/newsfragments.

@justinpakzad

Copy link
Copy Markdown
Contributor Author

Seems to be an unrelated test that's failing.

@SameerMesiah97 SameerMesiah97 left a comment

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.

I have left a few comments.

Comment thread providers/postgres/src/airflow/providers/postgres/hooks/postgres.py Outdated
Comment thread providers/postgres/src/airflow/providers/postgres/hooks/postgres.py Outdated
Comment thread providers/postgres/tests/unit/postgres/hooks/test_postgres.py
Comment thread providers/postgres/tests/unit/postgres/hooks/test_postgres.py
@justinpakzad
justinpakzad force-pushed the fix/postgres-hook-host-clusid-none-handling branch from 99f9fc4 to 1e5d2a1 Compare February 17, 2026 23:50
@eladkal
eladkal requested review from dabla and o-nikolas February 18, 2026 07:43
@potiuk
potiuk merged commit f41ec5f into apache:main Mar 12, 2026
90 checks passed
PascalEgn pushed a commit to PascalEgn/airflow that referenced this pull request Mar 12, 2026
…ws iam token retrieval (apache#61965)

* Add validation for missing host and cluster/workgroup identifier in aws iam token retrieval

* mypy fix

* Cleaned up the handling of cluster id to be more explicit
Pyasma pushed a commit to Pyasma/airflow that referenced this pull request Mar 13, 2026
…ws iam token retrieval (apache#61965)

* Add validation for missing host and cluster/workgroup identifier in aws iam token retrieval

* mypy fix

* Cleaned up the handling of cluster id to be more explicit
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants