You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2022/08/04 18:13:25 UTC

[GitHub] [superset] hughhhh commented on a diff in pull request #20965: fix: save dataset and repopulate state

hughhhh commented on code in PR #20965:
URL: https://github.com/apache/superset/pull/20965#discussion_r938110772


##########
superset/models/helpers.py:
##########
@@ -1749,12 +1753,20 @@ def get_sqla_query(  # pylint: disable=too-many-arguments,too-many-locals,too-ma
                 inner_time_filter = []
 
                 if dttm_col and not db_engine_spec.time_groupby_inline:
-                    inner_time_filter = [
-                        dttm_col.get_time_filter(
-                            inner_from_dttm or from_dttm,
-                            inner_to_dttm or to_dttm,
-                        )
-                    ]
+                    if isinstance(dttm_col, dict):

Review Comment:
   Use this pattern instead for grabbing the time_filter:
   https://github.com/preset-io/superset/blob/master/superset/models/helpers.py#L1550



-- 
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-unsubscribe@superset.apache.org

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


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