"""Add average_speed and stop_delay

Revision ID: aac025d432f0
Revises: bb5c406b9af5
Create Date: 2026-01-02 22:36:27.855381

"""
from typing import Sequence, Union

from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision: str = 'aac025d432f0'
down_revision: Union[str, None] = 'bb5c406b9af5'
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! ###
    op.add_column('route_stops', sa.Column('stop_delay_minutes', sa.Integer(), server_default='0', nullable=False))
    op.add_column('routes', sa.Column('average_speed_kmh', sa.Float(), nullable=True))
    # ### end Alembic commands ###


def downgrade() -> None:
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_column('routes', 'average_speed_kmh')
    op.drop_column('route_stops', 'stop_delay_minutes')
    # ### end Alembic commands ###

