Compare commits

..

No commits in common. "1b484da27aa0c783b2052d3f498d184dbd5d76a2" and "5abdd8414d2851228915d5415544ad13f665660c" have entirely different histories.

3 changed files with 14 additions and 25 deletions

View file

@ -2,17 +2,11 @@
## [Unreleased]
## 0.7.4
Date: 2025-02-12
- 🐛 — Fix method enum in tasks table (thx to Dryusdan)
## 0.7.3
Date: 2025-01-26
- 🐛 — Fix bug in retry_before_notification logic when success
🐛 — Fix bug in retry_before_notification logic when success
## 0.7.2

View file

@ -1 +1 @@
VERSION = "0.7.4"
VERSION = "0.7.3"

View file

@ -5,7 +5,6 @@ Revises: c780864dc407
Create Date: 2024-11-26 14:40:27.510587
"""
from typing import Sequence, Union
from alembic import op
@ -20,7 +19,11 @@ depends_on: Union[str, Sequence[str], None] = None
def upgrade() -> None:
enum = sa.Enum(
with op.batch_alter_table("tasks", schema=None) as batch_op:
batch_op.add_column(
sa.Column(
"method",
sa.Enum(
"GET",
"HEAD",
"POST",
@ -31,14 +34,7 @@ def upgrade() -> None:
"PATCH",
"DELETE",
name="method",
create_type=False,
)
enum.create(op.get_bind(), checkfirst=True)
with op.batch_alter_table("tasks", schema=None) as batch_op:
batch_op.add_column(
sa.Column(
"method",
enum,
),
nullable=False,
server_default="GET",
)
@ -48,4 +44,3 @@ def upgrade() -> None:
def downgrade() -> None:
with op.batch_alter_table("tasks", schema=None) as batch_op:
batch_op.drop_column("method")
sa.Enum(name="method").drop(op.get_bind(), checkfirst=True)