mistercrunch commented on a change in pull request #4724: Improve database type 
inference
URL: 
https://github.com/apache/incubator-superset/pull/4724#discussion_r178483201
 
 

 ##########
 File path: superset/dataframe.py
 ##########
 @@ -95,7 +141,7 @@ def agg_func(cls, dtype, column_name):
         # consider checking for key substring too.
         if cls.is_id(column_name):
             return 'count_distinct'
-        if (issubclass(dtype.type, np.generic) and
+        if (hasattr(dtype, 'tupe') and issubclass(dtype.type, np.generic) and
 
 Review comment:
   Typo, the intent was to check that `dtype.type` actually exists. I'm not 
100% sure whether I actually hit a missing attr or if it was preventative.

----------------------------------------------------------------
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:
[email protected]


With regards,
Apache Git Services

Reply via email to