mirror of
https://github.com/Monadical-SAS/reflector.git
synced 2025-12-20 20:29:06 +00:00
* refactor: fixes transcript duration type, NaN in waveform, and prepare for postgres migration * fix: ensure we don't have NaN in waveform * fix: missing assertionerror Co-authored-by: pr-agent-monadical[bot] <198624643+pr-agent-monadical[bot]@users.noreply.github.com> * fix: potential empty array --------- Co-authored-by: pr-agent-monadical[bot] <198624643+pr-agent-monadical[bot]@users.noreply.github.com>
40 lines
1.1 KiB
Python
40 lines
1.1 KiB
Python
"""transcript composite index
|
|
|
|
Revision ID: a9c9c229ee36
|
|
Revises: 88d292678ba2
|
|
Create Date: 2025-07-15 20:09:40.253018
|
|
|
|
"""
|
|
|
|
from typing import Sequence, Union
|
|
|
|
from alembic import op
|
|
import sqlalchemy as sa
|
|
from sqlalchemy.dialects import postgresql
|
|
|
|
# revision identifiers, used by Alembic.
|
|
revision: str = "a9c9c229ee36"
|
|
down_revision: Union[str, None] = "88d292678ba2"
|
|
branch_labels: Union[str, Sequence[str], None] = None
|
|
depends_on: Union[str, Sequence[str], None] = None
|
|
|
|
|
|
def upgrade() -> None:
|
|
# ### commands auto generated by Alembic - please adjust! ###
|
|
with op.batch_alter_table("transcript", schema=None) as batch_op:
|
|
batch_op.create_index(
|
|
"idx_transcript_user_id_recording_id",
|
|
["user_id", "recording_id"],
|
|
unique=False,
|
|
)
|
|
|
|
# ### end Alembic commands ###
|
|
|
|
|
|
def downgrade() -> None:
|
|
# ### commands auto generated by Alembic - please adjust! ###
|
|
with op.batch_alter_table("transcript", schema=None) as batch_op:
|
|
batch_op.drop_index("idx_transcript_user_id_recording_id")
|
|
|
|
# ### end Alembic commands ###
|