HarshithGamini commented on issue #12066:
URL: https://github.com/apache/superset/issues/12066#issuecomment-3080048033

   The root cause is the backend logic to get_data( ) in `class 
TimeTableViz(BaseViz):`
   `
   ```
   @deprecated(deprecated_in="3.0")
       def get_data(self, df: pd.DataFrame) -> VizData:
           if df.empty:
               return None
   ```
   
           columns = None
           values: list[str] | str = self.metric_labels
           if self.form_data.get("groupby"):
               values = self.metric_labels[0]
               columns = get_column_names(self.form_data.get("groupby"))
           pt = df.pivot_table(index=DTTM_ALIAS, columns=columns, values=values)
           pt.index = pt.index.map(str)
           pt = pt.sort_index()
           return {
               "records": pt.to_dict(orient="index"),
               "columns": list(pt.columns),
               "is_group_by": bool(self.form_data.get("groupby")),
           }
   `
   @rusackas, Is this supposed to be deprecated in 3.0?
   The time-series table chart still uses it as of latest master, we could 
implement a fix as mentioned by @dosu to flatten tuple keys to strings before 
returning the dictionary.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@superset.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscr...@superset.apache.org
For additional commands, e-mail: notifications-h...@superset.apache.org

Reply via email to