summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/exc.py
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2021-10-26 15:37:16 -0400
committerMike Bayer <mike_mp@zzzcomputing.com>2021-10-27 11:41:00 -0400
commit0f98ead274df103a5a623baa3898580932e1c8e2 (patch)
treef2c9acf56b9144e7ce3817a6066fedbe481ef540 /lib/sqlalchemy/exc.py
parentd2cf7dcfe0cd7e9986376b6e7edd4b7d60108599 (diff)
downloadsqlalchemy-0f98ead274df103a5a623baa3898580932e1c8e2.tar.gz
deprecation warnings: with_parent, aliased, from_joinpoint
most of the work for aliased / from_joinpoint has been done already as I added all new tests for these and moved most aliased/from_joinpoint to test/orm/test_deprecations.py already Change-Id: Ia23e332dec183de17b2fb9d89d946af8d5e89ae7
Diffstat (limited to 'lib/sqlalchemy/exc.py')
-rw-r--r--lib/sqlalchemy/exc.py15
1 files changed, 12 insertions, 3 deletions
diff --git a/lib/sqlalchemy/exc.py b/lib/sqlalchemy/exc.py
index 9b9c82aca..7fa77120c 100644
--- a/lib/sqlalchemy/exc.py
+++ b/lib/sqlalchemy/exc.py
@@ -685,8 +685,9 @@ class SADeprecationWarning(HasDescriptionCode, DeprecationWarning):
"Indicates the version that started raising this deprecation warning"
-class RemovedIn20Warning(SADeprecationWarning):
- """Issued for usage of APIs specifically deprecated in SQLAlchemy 2.0.
+class Base20DeprecationWarning(SADeprecationWarning):
+ """Issued for usage of APIs specifically deprecated or legacy in
+ SQLAlchemy 2.0.
.. seealso::
@@ -701,11 +702,19 @@ class RemovedIn20Warning(SADeprecationWarning):
def __str__(self):
return (
- super(RemovedIn20Warning, self).__str__()
+ super(Base20DeprecationWarning, self).__str__()
+ " (Background on SQLAlchemy 2.0 at: https://sqlalche.me/e/b8d9)"
)
+class LegacyAPIWarning(Base20DeprecationWarning):
+ """indicates an API that is in 'legacy' status, a long term deprecation."""
+
+
+class RemovedIn20Warning(Base20DeprecationWarning):
+ """indicates an API that will be fully removed in SQLAlchemy 2.0."""
+
+
class MovedIn20Warning(RemovedIn20Warning):
"""Subtype of RemovedIn20Warning to indicate an API that moved only."""