jedcunningham opened a new pull request, #74863:
URL: https://github.com/apache/airflow/pull/74863
Airflow emitted a `FutureWarning` ("Bad scheme ... You must change to
`postgresql+psycopg`") for bare `postgresql://` metadata DB URLs. Those URLs
are valid: Airflow only rewrites them to make the driver explicit
(`postgresql+psycopg` if psycopg 3 is installed, otherwise
`postgresql+psycopg2`). Users read the warning as "driver-less URLs are
deprecated".
This change:
- stops warning for bare `postgresql://` (the rewrite itself is unchanged);
- keeps the warning for the actually unsupported `postgres://` and
`postgres+psycopg2://` schemes, reworded to say what Airflow does and that
`postgresql` (driver picked by Airflow) is a valid fix; the outdated SQLAlchemy
1.4 / Airflow 2.3 reference and the "before the next Airflow release" deadline
are dropped;
- updates the `_upgrade_postgres_metastore_conn` docstring accordingly;
- adds a test that the warning is emitted only for `postgres` /
`postgres+psycopg2`, and not for bare `postgresql`.
--
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]