Skip to content

Commit ab4fe38

Browse files
committed
Fix #149: PostgresRangePartitioningStrategy should derive from PostgresPartitioningStrategy
1 parent 6a1bc29 commit ab4fe38

File tree

1 file changed

+2
-17
lines changed

1 file changed

+2
-17
lines changed
Lines changed: 2 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,9 @@
1-
from abc import abstractmethod
2-
from typing import Generator
1+
from .strategy import PostgresPartitioningStrategy
32

4-
from .range_partition import PostgresRangePartition
53

6-
7-
class PostgresRangePartitioningStrategy:
4+
class PostgresRangePartitioningStrategy(PostgresPartitioningStrategy):
85
"""Base class for implementing a partitioning strategy for a range
96
partitioned table."""
107

11-
@abstractmethod
12-
def to_create(
13-
self,
14-
) -> Generator[PostgresRangePartition, None, None]:
15-
"""Generates a list of partitions to be created."""
16-
17-
@abstractmethod
18-
def to_delete(
19-
self,
20-
) -> Generator[PostgresRangePartition, None, None]:
21-
"""Generates a list of partitions to be deleted."""
22-
238

249
__all__ = ["PostgresRangePartitioningStrategy"]

0 commit comments

Comments
 (0)