Skip to content

Commit

Permalink
Fix db migration 3dda56f1c4c6 (apache#5415)
Browse files Browse the repository at this point in the history
(cherry picked from commit 73ec526)
  • Loading branch information
mistercrunch authored and Grace Guo committed Jul 26, 2018
1 parent 8c03fab commit c9867a6
Showing 1 changed file with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,20 @@
from __future__ import division

# revision identifiers, used by Alembic.
revision = '3dda56f1c4c6'
down_revision = 'bddc498dd179'

import datetime
import json

from alembic import op
import isodate
import sqlalchemy as sa
from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy import Column, Integer, Text

from superset import db
from superset.utils import parse_human_timedelta

revision = '3dda56f1c4c6'
down_revision = 'bddc498dd179'


Base = declarative_base()
Expand Down Expand Up @@ -96,6 +98,8 @@ def format_seconds(value):


def compute_time_compare(granularity, periods):
if not granularity:
return None
# convert old db_engine_spec granularity to ISO duration
if granularity in db_engine_specs_map:
granularity = db_engine_specs_map[granularity]
Expand Down

0 comments on commit c9867a6

Please sign in to comment.