Skip to content

Commit

Permalink
Replace deprecated @abstractproperty
Browse files Browse the repository at this point in the history
  • Loading branch information
dantownsend committed Jun 13, 2024
1 parent fb7a5ed commit d59ef78
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
8 changes: 5 additions & 3 deletions piccolo/columns/defaults/base.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,19 @@
from __future__ import annotations

import typing as t
from abc import ABC, abstractmethod, abstractproperty
from abc import ABC, abstractmethod

from piccolo.utils.repr import repr_class_instance


class Default(ABC):
@abstractproperty
@property
@abstractmethod
def postgres(self) -> str:
pass

@abstractproperty
@property
@abstractmethod
def sqlite(self) -> str:
pass

Expand Down
3 changes: 2 additions & 1 deletion piccolo/schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ class SchemaDDLBase(abc.ABC):

db: Engine

@abc.abstractproperty
@property
@abc.abstractmethod
def ddl(self) -> str:
pass

Expand Down

0 comments on commit d59ef78

Please sign in to comment.