GayathriSrividya opened a new pull request, #69878:
URL: https://github.com/apache/airflow/pull/69878

   closes: #68707
   
   Use this PR description:
   
   Title:
   Show clear error for invalid sql_alchemy_conn at startup
   
   Body:
   ## Summary
   
   This PR improves startup error handling when database.sql_alchemy_conn is 
invalid.
   
   Changes included:
   1. Added validation in settings URI conversion so malformed connection URIs 
fail with a clear, actionable ValueError.
   2. Error message now points users to both 
AIRFLOW__DATABASE__SQL_ALCHEMY_CONN and sql_alchemy_conn in airflow.cfg.
   3. Refactored URI-conversion tests into parametrized cases for supported 
schemes and invalid inputs.
   4. Kept PostgreSQL test expectations compatible with the active async driver 
selection (psycopg_async vs asyncpg).
   
   ## Why
   
   Previously, malformed SQLAlchemy connection URIs could fail in a less clear 
way during startup. This makes failures easier to diagnose and faster to fix.
   
   ## Testing
   
   1. Updated unit tests in airflow-core tests for settings URI conversion.
   2. Ruff format/check run on modified files.
   3. Local targeted pytest via uv was blocked by a provider import issue in 
this environment; changes are covered by updated unit tests and will be 
validated in CI.
   
   ## Reviewer
   
   Requested reviewer: @justinpakzad
   
   
    


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to