NathanQuinn commented on issue #4755: Pass granularity from backend to frontend 
as ISO duration
   @betodealmeida @mistercrunch 
   I exported a postgres backed set of charts and dashboards to another 
postgres instance with this change included. It seems to work when viewing the 
actual chart, but when a time grain is persisted on a chart used in a dashboard 
I'm getting an error as such:
   Traceback (most recent call last):
     File "/home/superset/superset/", line 362, in get_df_payload
       df = self.get_df(query_obj)
     File "/home/superset/superset/", line 160, in get_df
       self.results = self.datasource.query(query_obj)
     File "/home/superset/superset/connectors/sqla/", line 705, in 
       sql = self.get_query_str(query_obj)
     File "/home/superset/superset/connectors/sqla/", line 419, in 
       qry = self.get_sqla_query(**query_obj)
     File "/home/superset/superset/connectors/sqla/", line 545, in 
       timestamp = dttm_col.get_timestamp_expression(time_grain)
     File "/home/superset/superset/connectors/sqla/", line 134, in 
       expr = grain.function.format(col=expr)
   AttributeError: 'str' object has no attribute 'function'
   I was able to backfill values stored on slices.params.time_grain_sqla, to 
the ISO durations from 
 and this resolved the issue.  Did I miss a migration someplace or should one 
be added for this?

This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:

With regards,
Apache Git Services

Reply via email to