From ea5a4172380fcafe2b7422d78f2e3953ea52cfe4 Mon Sep 17 00:00:00 2001 From: serenajiang Date: Thu, 31 Mar 2022 12:47:02 -0700 Subject: [PATCH] fix: handle null params in #18936 migration (#19474) --- .../versions/ab9a9d86e695_deprecate_time_range_endpoints.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/superset/migrations/versions/ab9a9d86e695_deprecate_time_range_endpoints.py b/superset/migrations/versions/ab9a9d86e695_deprecate_time_range_endpoints.py index 0ce9bd5237d8f..3f149d3ff0c2a 100644 --- a/superset/migrations/versions/ab9a9d86e695_deprecate_time_range_endpoints.py +++ b/superset/migrations/versions/ab9a9d86e695_deprecate_time_range_endpoints.py @@ -47,7 +47,7 @@ def upgrade(): session = db.Session(bind=bind) for slc in session.query(Slice): - params = json.loads(slc.params) + params = json.loads(slc.params or "{}") params.pop("time_range_endpoints", None) slc.params = json.dumps(params)