]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
Deprecate bound metadata
authorMike Bayer <mike_mp@zzzcomputing.com>
Mon, 12 Oct 2020 17:16:14 +0000 (13:16 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Mon, 12 Oct 2020 17:57:43 +0000 (13:57 -0400)
commitc76e3776f52d0d69c8c4932ba53626d7190cf5f4
tree224282cf4390f136228a932a40dbb504824b273b
parent286fe9b0b165e46099066cc16552b93a0b853a7e
Deprecate bound metadata

The :paramref:`_schema.MetaData.bind` argument as well as the overall
concept of "bound metadata" is deprecated in SQLAlchemy 1.4 and will be
removed in SQLAlchemy 2.0.  The parameter as well as related functions now
emit a :class:`_exc.RemovedIn20Warning` when :ref:`deprecation_20_mode` is
in use.

Added new parameter :paramref:`_automap.AutomapBase.prepare.autoload_with`
which supersedes :paramref:`_automap.AutomapBase.prepare.reflect`
and :paramref:`_automap.AutomapBase.prepare.engine`.

Fixes: #4634
Fixes: #5142
Change-Id: Iaabf9b481931e2fb68b97b5954c32e65772a298e
doc/build/changelog/unreleased_14/4634.rst [new file with mode: 0644]
lib/sqlalchemy/ext/automap.py
lib/sqlalchemy/sql/base.py
lib/sqlalchemy/sql/schema.py
lib/sqlalchemy/testing/warnings.py
test/ext/test_automap.py
test/ext/test_deprecations.py
test/sql/test_deprecations.py