Fix startup when there's no live layers in reds

This commit is contained in:
phil 2023-12-21 17:16:50 +05:30
parent 1e2802f289
commit f47e018e65

View file

@ -623,7 +623,10 @@ class ModelRegistry:
inplace=True)
df_live = pd.DataFrame.from_dict(self.geom_live_defs.values(),
orient='columns'
).set_index('store')
)
if len(df_live) == 0:
return
df_live.set_index('store', inplace=True)
## Adjust column names
## and add columns, to make sure pandas dtypes are not changed when the
## dataframes are concat