sqlalchemy: Use built-in declarative

sqlalchemy.ext.declarative was deprecated in sqlalchemy 1.4.0, due to
the built-in implementations[1].

[1] https://github.com/sqlalchemy/sqlalchemy/commit/450f5c0d6519a439f40

Change-Id: Idb4a361d4d65ff53ecf33b8a2a6aa0d6f6ae1979
This commit is contained in:
Takashi Kajinami
2025-06-30 22:14:17 +09:00
parent 76de167171
commit 828bcadf6a

View File

@@ -21,7 +21,6 @@ from oslo_serialization import jsonutils
from sqlalchemy import Boolean from sqlalchemy import Boolean
from sqlalchemy import Column from sqlalchemy import Column
from sqlalchemy import DateTime from sqlalchemy import DateTime
from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy import Float from sqlalchemy import Float
from sqlalchemy import ForeignKey from sqlalchemy import ForeignKey
from sqlalchemy import Integer from sqlalchemy import Integer
@@ -94,7 +93,7 @@ class WatcherBase(models.SoftDeleteMixin,
return d return d
Base = declarative_base(cls=WatcherBase) Base = orm.declarative_base(cls=WatcherBase)
class Goal(Base): class Goal(Base):