superset-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] findepi opened a new issue #4926: SQL Lab: Stop query button sometimes results in "Internal Server Error" response rendered in results' pane
Date Thu, 03 May 2018 13:02:23 GMT
findepi opened a new issue #4926: SQL Lab: Stop query button sometimes results in "Internal
Server Error" response rendered in results' pane
URL: https://github.com/apache/incubator-superset/issues/4926
 
 
   Make sure these boxes are checked before submitting your issue - thank you!
   
   - [x] I have checked the superset logs for python stacktraces and included it here as text
if any
   - [x] I have reproduced the issue with at least the latest released version of superset
   - [x] I have checked the issue tracker for the same issue and I haven't found one similar
   
   
   ### Superset version
   
   0.24.0
   
   ### Expected results
   
   Query stopped.
   
   ### Actual results
   
   UI:
   Yellow rectangle with "Query was stopped" is shown for a moment, but then it's replaced
with a red rectangle with the following:
   
   ```
   <html> <body> <h1>Sorry, something went wrong</h1> <h3>500
- Internal Server Error</h3> <hr> <h2>Stacktrace</h2> <hr> <code>
<pre> Traceback (most recent call last): File &#34;/usr/local/lib/python2.7/dist-packages/flask/app.py&#34;,
line 1982, in wsgi_app response = self.full_dispatch_request() File &#34;/usr/local/lib/python2.7/dist-packages/flask/app.py&#34;,
line 1614, in full_dispatch_request rv = self.handle_user_exception(e) File &#34;/usr/local/lib/python2.7/dist-packages/flask/app.py&#34;,
line 1517, in handle_user_exception reraise(exc_type, exc_value, tb) File &#34;/usr/local/lib/python2.7/dist-packages/flask/app.py&#34;,
line 1612, in full_dispatch_request rv = self.dispatch_request() File &#34;/usr/local/lib/python2.7/dist-packages/flask/app.py&#34;,
line 1598, in dispatch_request return self.view_functions[rule.endpoint](**req.view_args)
File &#34;/usr/local/lib/python2.7/dist-packages/flask_appbuilder/security/decorators.py&#34;,
line 52, in wraps return f(self, *args, **kwargs) File &#34;/usr/local/lib/python2.7/dist-packages/superset/models/core.py&#34;,
line 899, in wrapper value = f(*args, **kwargs) File &#34;/usr/local/lib/python2.7/dist-packages/superset/views/core.py&#34;,
line 2458, in sql_json if data.get(&#39;status&#39;) == QueryStatus.FAILED: AttributeError:
&#39;str&#39; object has no attribute &#39;get&#39; </pre> </code>
</body> </html>
   ```
   
   screenshot:
   ![image](https://user-images.githubusercontent.com/144328/39577648-32d5e38a-4ee2-11e8-8ca1-ddc54e531450.png)
   
   
   Webapp output:
   
   ```
   2018-05-03 12:52:18,152:DEBUG:root:[stats_logger] (incr) sql_json
   2018-05-03 12:52:18,156:INFO:root:Parsing with sqlparse statement WITH
     ss AS (
      SELECT
        "i_manufact_id"
      , "sum"("ss_ext_sales_price") "total_sales"
      FROM
        store_sales
      , date_dim
      , customer_address
      , item
      WHERE ("i_manufact_id" IN (
         SELECT "i_manufact_id"
         FROM
           item
         WHERE ("i_category" IN ('Electronics                                       '))
      ))
         AND ("ss_item_sk" = "i_item_sk")
         AND ("ss_sold_date_sk" = "d_date_sk")
         AND ("d_year" = 1998)
         AND ("d_moy" = 5)
         AND ("ss_addr_sk" = "ca_address_sk")
         AND ("ca_gmt_offset" = -5)
      GROUP BY "i_manufact_id"
   )
   , cs AS (
      SELECT
        "i_manufact_id"
      , "sum"("cs_ext_sales_price") "total_sales"
      FROM
        catalog_sales
      , date_dim
      , customer_address
      , item
      WHERE ("i_manufact_id" IN (
         SELECT "i_manufact_id"
         FROM
           item
         WHERE ("i_category" IN ('Electronics                                       '))
      ))
         AND ("cs_item_sk" = "i_item_sk")
         AND ("cs_sold_date_sk" = "d_date_sk")
         AND ("d_year" = 1998)
         AND ("d_moy" = 5)
         AND ("cs_bill_addr_sk" = "ca_address_sk")
         AND ("ca_gmt_offset" = -5)
      GROUP BY "i_manufact_id"
   )
   , ws AS (
      SELECT
        "i_manufact_id"
      , "sum"("ws_ext_sales_price") "total_sales"
      FROM
        web_sales
      , date_dim
      , customer_address
      , item
      WHERE ("i_manufact_id" IN (
         SELECT "i_manufact_id"
         FROM
           item
         WHERE ("i_category" IN ('Electronics                                       '))
      ))
         AND ("ws_item_sk" = "i_item_sk")
         AND ("ws_sold_date_sk" = "d_date_sk")
         AND ("d_year" = 1998)
         AND ("d_moy" = 5)
         AND ("ws_bill_addr_sk" = "ca_address_sk")
         AND ("ca_gmt_offset" = -5)
      GROUP BY "i_manufact_id"
   )
   SELECT
     "i_manufact_id"
   , "sum"("total_sales") "total_sales"
   FROM
     (
      SELECT *
      FROM
        ss
   UNION ALL    SELECT *
      FROM
        cs
   UNION ALL    SELECT *
      FROM
        ws
   )  tmp1
   GROUP BY "i_manufact_id"
   ORDER BY "total_sales" ASC
   LIMIT 100
   
   2018-05-03 12:52:18,207:INFO:root:Triggering query_id: 7
   2018-05-03 12:52:18,214:INFO:root:Parsing with sqlparse statement WITH
     ss AS (
      SELECT
        "i_manufact_id"
      , "sum"("ss_ext_sales_price") "total_sales"
      FROM
        store_sales
      , date_dim
      , customer_address
      , item
      WHERE ("i_manufact_id" IN (
         SELECT "i_manufact_id"
         FROM
           item
         WHERE ("i_category" IN ('Electronics                                       '))
      ))
         AND ("ss_item_sk" = "i_item_sk")
         AND ("ss_sold_date_sk" = "d_date_sk")
         AND ("d_year" = 1998)
         AND ("d_moy" = 5)
         AND ("ss_addr_sk" = "ca_address_sk")
         AND ("ca_gmt_offset" = -5)
      GROUP BY "i_manufact_id"
   )
   , cs AS (
      SELECT
        "i_manufact_id"
      , "sum"("cs_ext_sales_price") "total_sales"
      FROM
        catalog_sales
      , date_dim
      , customer_address
      , item
      WHERE ("i_manufact_id" IN (
         SELECT "i_manufact_id"
         FROM
           item
         WHERE ("i_category" IN ('Electronics                                       '))
      ))
         AND ("cs_item_sk" = "i_item_sk")
         AND ("cs_sold_date_sk" = "d_date_sk")
         AND ("d_year" = 1998)
         AND ("d_moy" = 5)
         AND ("cs_bill_addr_sk" = "ca_address_sk")
         AND ("ca_gmt_offset" = -5)
      GROUP BY "i_manufact_id"
   )
   , ws AS (
      SELECT
        "i_manufact_id"
      , "sum"("ws_ext_sales_price") "total_sales"
      FROM
        web_sales
      , date_dim
      , customer_address
      , item
      WHERE ("i_manufact_id" IN (
         SELECT "i_manufact_id"
         FROM
           item
         WHERE ("i_category" IN ('Electronics                                       '))
      ))
         AND ("ws_item_sk" = "i_item_sk")
         AND ("ws_sold_date_sk" = "d_date_sk")
         AND ("d_year" = 1998)
         AND ("d_moy" = 5)
         AND ("ws_bill_addr_sk" = "ca_address_sk")
         AND ("ca_gmt_offset" = -5)
      GROUP BY "i_manufact_id"
   )
   SELECT
     "i_manufact_id"
   , "sum"("total_sales") "total_sales"
   FROM
     (
      SELECT *
      FROM
        ss
   UNION ALL    SELECT *
      FROM
        cs
   UNION ALL    SELECT *
      FROM
        ws
   )  tmp1
   GROUP BY "i_manufact_id"
   ORDER BY "total_sales" ASC
   LIMIT 100
   
   2018-05-03 12:52:18,249:INFO:root:Set query to 'running'
   2018-05-03 12:52:18,256:INFO:root:Database.get_sqla_engine(). Masked URL: presto://presto:8080/tpcds/sf1
   2018-05-03 12:52:18,258:INFO:root:Running query:
   WITH
     ss AS (
      SELECT
        "i_manufact_id"
      , "sum"("ss_ext_sales_price") "total_sales"
      FROM
        store_sales
      , date_dim
      , customer_address
      , item
      WHERE ("i_manufact_id" IN (
         SELECT "i_manufact_id"
         FROM
           item
         WHERE ("i_category" IN ('Electronics                                       '))
      ))
         AND ("ss_item_sk" = "i_item_sk")
         AND ("ss_sold_date_sk" = "d_date_sk")
         AND ("d_year" = 1998)
         AND ("d_moy" = 5)
         AND ("ss_addr_sk" = "ca_address_sk")
         AND ("ca_gmt_offset" = -5)
      GROUP BY "i_manufact_id"
   )
   , cs AS (
      SELECT
        "i_manufact_id"
      , "sum"("cs_ext_sales_price") "total_sales"
      FROM
        catalog_sales
      , date_dim
      , customer_address
      , item
      WHERE ("i_manufact_id" IN (
         SELECT "i_manufact_id"
         FROM
           item
         WHERE ("i_category" IN ('Electronics                                       '))
      ))
         AND ("cs_item_sk" = "i_item_sk")
         AND ("cs_sold_date_sk" = "d_date_sk")
         AND ("d_year" = 1998)
         AND ("d_moy" = 5)
         AND ("cs_bill_addr_sk" = "ca_address_sk")
         AND ("ca_gmt_offset" = -5)
      GROUP BY "i_manufact_id"
   )
   , ws AS (
      SELECT
        "i_manufact_id"
      , "sum"("ws_ext_sales_price") "total_sales"
      FROM
        web_sales
      , date_dim
      , customer_address
      , item
      WHERE ("i_manufact_id" IN (
         SELECT "i_manufact_id"
         FROM
           item
         WHERE ("i_category" IN ('Electronics                                       '))
      ))
         AND ("ws_item_sk" = "i_item_sk")
         AND ("ws_sold_date_sk" = "d_date_sk")
         AND ("d_year" = 1998)
         AND ("d_moy" = 5)
         AND ("ws_bill_addr_sk" = "ca_address_sk")
         AND ("ca_gmt_offset" = -5)
      GROUP BY "i_manufact_id"
   )
   SELECT
     "i_manufact_id"
   , "sum"("total_sales") "total_sales"
   FROM
     (
      SELECT *
      FROM
        ss
   UNION ALL    SELECT *
      FROM
        cs
   UNION ALL    SELECT *
      FROM
        ws
   )  tmp1
   GROUP BY "i_manufact_id"
   ORDER BY "total_sales" ASC
   LIMIT 100
   2018-05-03 12:52:18,258:INFO:root:WITH
     ss AS (
      SELECT
        "i_manufact_id"
      , "sum"("ss_ext_sales_price") "total_sales"
      FROM
        store_sales
      , date_dim
      , customer_address
      , item
      WHERE ("i_manufact_id" IN (
         SELECT "i_manufact_id"
         FROM
           item
         WHERE ("i_category" IN ('Electronics                                       '))
      ))
         AND ("ss_item_sk" = "i_item_sk")
         AND ("ss_sold_date_sk" = "d_date_sk")
         AND ("d_year" = 1998)
         AND ("d_moy" = 5)
         AND ("ss_addr_sk" = "ca_address_sk")
         AND ("ca_gmt_offset" = -5)
      GROUP BY "i_manufact_id"
   )
   , cs AS (
      SELECT
        "i_manufact_id"
      , "sum"("cs_ext_sales_price") "total_sales"
      FROM
        catalog_sales
      , date_dim
      , customer_address
      , item
      WHERE ("i_manufact_id" IN (
         SELECT "i_manufact_id"
         FROM
           item
         WHERE ("i_category" IN ('Electronics                                       '))
      ))
         AND ("cs_item_sk" = "i_item_sk")
         AND ("cs_sold_date_sk" = "d_date_sk")
         AND ("d_year" = 1998)
         AND ("d_moy" = 5)
         AND ("cs_bill_addr_sk" = "ca_address_sk")
         AND ("ca_gmt_offset" = -5)
      GROUP BY "i_manufact_id"
   )
   , ws AS (
      SELECT
        "i_manufact_id"
      , "sum"("ws_ext_sales_price") "total_sales"
      FROM
        web_sales
      , date_dim
      , customer_address
      , item
      WHERE ("i_manufact_id" IN (
         SELECT "i_manufact_id"
         FROM
           item
         WHERE ("i_category" IN ('Electronics                                       '))
      ))
         AND ("ws_item_sk" = "i_item_sk")
         AND ("ws_sold_date_sk" = "d_date_sk")
         AND ("d_year" = 1998)
         AND ("d_moy" = 5)
         AND ("ws_bill_addr_sk" = "ca_address_sk")
         AND ("ca_gmt_offset" = -5)
      GROUP BY "i_manufact_id"
   )
   SELECT
     "i_manufact_id"
   , "sum"("total_sales") "total_sales"
   FROM
     (
      SELECT *
      FROM
        ss
   UNION ALL    SELECT *
      FROM
        cs
   UNION ALL    SELECT *
      FROM
        ws
   )  tmp1
   GROUP BY "i_manufact_id"
   ORDER BY "total_sales" ASC
   LIMIT 100
   2018-05-03 12:52:18,258:INFO:pyhive.presto:WITH
     ss AS (
      SELECT
        "i_manufact_id"
      , "sum"("ss_ext_sales_price") "total_sales"
      FROM
        store_sales
      , date_dim
      , customer_address
      , item
      WHERE ("i_manufact_id" IN (
         SELECT "i_manufact_id"
         FROM
           item
         WHERE ("i_category" IN ('Electronics                                       '))
      ))
         AND ("ss_item_sk" = "i_item_sk")
         AND ("ss_sold_date_sk" = "d_date_sk")
         AND ("d_year" = 1998)
         AND ("d_moy" = 5)
         AND ("ss_addr_sk" = "ca_address_sk")
         AND ("ca_gmt_offset" = -5)
      GROUP BY "i_manufact_id"
   )
   , cs AS (
      SELECT
        "i_manufact_id"
      , "sum"("cs_ext_sales_price") "total_sales"
      FROM
        catalog_sales
      , date_dim
      , customer_address
      , item
      WHERE ("i_manufact_id" IN (
         SELECT "i_manufact_id"
         FROM
           item
         WHERE ("i_category" IN ('Electronics                                       '))
      ))
         AND ("cs_item_sk" = "i_item_sk")
         AND ("cs_sold_date_sk" = "d_date_sk")
         AND ("d_year" = 1998)
         AND ("d_moy" = 5)
         AND ("cs_bill_addr_sk" = "ca_address_sk")
         AND ("ca_gmt_offset" = -5)
      GROUP BY "i_manufact_id"
   )
   , ws AS (
      SELECT
        "i_manufact_id"
      , "sum"("ws_ext_sales_price") "total_sales"
      FROM
        web_sales
      , date_dim
      , customer_address
      , item
      WHERE ("i_manufact_id" IN (
         SELECT "i_manufact_id"
         FROM
           item
         WHERE ("i_category" IN ('Electronics                                       '))
      ))
         AND ("ws_item_sk" = "i_item_sk")
         AND ("ws_sold_date_sk" = "d_date_sk")
         AND ("d_year" = 1998)
         AND ("d_moy" = 5)
         AND ("ws_bill_addr_sk" = "ca_address_sk")
         AND ("ca_gmt_offset" = -5)
      GROUP BY "i_manufact_id"
   )
   SELECT
     "i_manufact_id"
   , "sum"("total_sales") "total_sales"
   FROM
     (
      SELECT *
      FROM
        ss
   UNION ALL    SELECT *
      FROM
        cs
   UNION ALL    SELECT *
      FROM
        ws
   )  tmp1
   GROUP BY "i_manufact_id"
   ORDER BY "total_sales" ASC
   LIMIT 100
   2018-05-03 12:52:18,264:DEBUG:urllib3.connectionpool:Starting new HTTP connection (1):
presto
   2018-05-03 12:52:18,294:DEBUG:urllib3.connectionpool:http://presto:8080 "POST /v1/statement
HTTP/1.1" 200 558
   2018-05-03 12:52:18,295:INFO:root:Handling cursor
   2018-05-03 12:52:18,296:INFO:root:Polling the cursor for progress
   2018-05-03 12:52:18,298:DEBUG:urllib3.connectionpool:Starting new HTTP connection (1):
presto
   2018-05-03 12:52:18,608:DEBUG:root:[stats_logger] (incr) queries
   2018-05-03 12:52:19,328:DEBUG:urllib3.connectionpool:http://presto:8080 "GET /v1/statement/20180503_125218_00028_hh3n5/1
HTTP/1.1" 200 656
   2018-05-03 12:52:19,336:INFO:root:Query progress: 7.0 / 8.0 splits
   2018-05-03 12:52:20,346:INFO:root:Polling the cursor for progress
   2018-05-03 12:52:20,348:DEBUG:urllib3.connectionpool:Starting new HTTP connection (1):
presto
   2018-05-03 12:52:20,605:DEBUG:root:[stats_logger] (incr) queries
   2018-05-03 12:52:21,357:DEBUG:urllib3.connectionpool:http://presto:8080 "GET /v1/statement/20180503_125218_00028_hh3n5/2
HTTP/1.1" 200 750
   2018-05-03 12:52:21,367:INFO:root:Query progress: 19.0 / 979.0 splits
   2018-05-03 12:52:22,370:INFO:root:Polling the cursor for progress
   2018-05-03 12:52:22,372:DEBUG:urllib3.connectionpool:Starting new HTTP connection (1):
presto
   2018-05-03 12:52:22,605:DEBUG:root:[stats_logger] (incr) queries
   2018-05-03 12:52:23,379:DEBUG:urllib3.connectionpool:http://presto:8080 "GET /v1/statement/20180503_125218_00028_hh3n5/3
HTTP/1.1" 200 922
   2018-05-03 12:52:23,388:INFO:root:Query progress: 302.0 / 979.0 splits
   2018-05-03 12:52:24,390:INFO:root:Polling the cursor for progress
   2018-05-03 12:52:24,392:DEBUG:urllib3.connectionpool:Starting new HTTP connection (1):
presto
   2018-05-03 12:52:24,607:DEBUG:root:[stats_logger] (incr) queries
   2018-05-03 12:52:25,093:DEBUG:root:[stats_logger] (incr) stop_query
   2018-05-03 12:52:25,398:DEBUG:urllib3.connectionpool:http://presto:8080 "GET /v1/statement/20180503_125218_00028_hh3n5/4
HTTP/1.1" 200 912
   2018-05-03 12:52:25,409:DEBUG:urllib3.connectionpool:Starting new HTTP connection (1):
presto
   2018-05-03 12:52:25,419:DEBUG:urllib3.connectionpool:http://presto:8080 "DELETE /v1/statement/20180503_125218_00028_hh3n5/5
HTTP/1.1" 204 0
   2018-05-03 12:52:25,430:INFO:root:Fetching data: {u'changedOn': datetime.datetime(2018,
5, 3, 12, 52, 25, 97450), u'tempTable': u'', u'userId': 1, u'executedSql': u'WITH\n  ss AS
(\n   SELECT\n     "i_manufact_id"\n   , "sum"("ss_ext_sales_price") "total_sales"\n   FROM\n
    store_sales\n   , date_dim\n   , customer_address\n   , item\n   WHERE ("i_manufact_id"
IN (\n      SELECT "i_manufact_id"\n      FROM\n        item\n      WHERE ("i_category" IN
(\'Electronics                                       \'))\n   ))\n      AND ("ss_item_sk"
= "i_item_sk")\n      AND ("ss_sold_date_sk" = "d_date_sk")\n      AND ("d_year" = 1998)\n
     AND ("d_moy" = 5)\n      AND ("ss_addr_sk" = "ca_address_sk")\n      AND ("ca_gmt_offset"
= -5)\n   GROUP BY "i_manufact_id"\n) \n, cs AS (\n   SELECT\n     "i_manufact_id"\n   , "sum"("cs_ext_sales_price")
"total_sales"\n   FROM\n     catalog_sales\n   , date_dim\n   , customer_address\n   , item\n
  WHERE ("i_manufact_id" IN (\n      SELECT "i_manufact_id"\n      FROM\n        item\n  
   WHERE ("i_category" IN (\'Electronics                                       \'))\n   ))\n
     AND ("cs_item_sk" = "i_item_sk")\n      AND ("cs_sold_date_sk" = "d_date_sk")\n     
AND ("d_year" = 1998)\n      AND ("d_moy" = 5)\n      AND ("cs_bill_addr_sk" = "ca_address_sk")\n
     AND ("ca_gmt_offset" = -5)\n   GROUP BY "i_manufact_id"\n) \n, ws AS (\n   SELECT\n 
   "i_manufact_id"\n   , "sum"("ws_ext_sales_price") "total_sales"\n   FROM\n     web_sales\n
  , date_dim\n   , customer_address\n   , item\n   WHERE ("i_manufact_id" IN (\n      SELECT
"i_manufact_id"\n      FROM\n        item\n      WHERE ("i_category" IN (\'Electronics   
                                   \'))\n   ))\n      AND ("ws_item_sk" = "i_item_sk")\n 
    AND ("ws_sold_date_sk" = "d_date_sk")\n      AND ("d_year" = 1998)\n      AND ("d_moy"
= 5)\n      AND ("ws_bill_addr_sk" = "ca_address_sk")\n      AND ("ca_gmt_offset" = -5)\n
  GROUP BY "i_manufact_id"\n) \nSELECT\n  "i_manufact_id"\n, "sum"("total_sales") "total_sales"\nFROM\n
 (\n   SELECT *\n   FROM\n     ss\nUNION ALL    SELECT *\n   FROM\n     cs\nUNION ALL    SELECT
*\n   FROM\n     ws\n)  tmp1\nGROUP BY "i_manufact_id"\nORDER BY "total_sales" ASC\nLIMIT
100', u'ctas': False, u'tab': u'Untitled Query', u'sqlEditorId': u'ryBUkK_aG', u'id': u'BJc-8tdaG',
u'changed_on': '2018-05-03T12:52:25.097450', u'rows': None, u'endDttm': None, u'limit_reached':
False, u'state': u'stopped', u'progress': 87.5, u'schema': u'sf1', u'dbId': 2, u'errorMessage':
None, u'db': u'Presto: tpcds', u'trackingUrl': None, u'user': u'admin', u'sql': u'WITH\n 
ss AS (\n   SELECT\n     "i_manufact_id"\n   , "sum"("ss_ext_sales_price") "total_sales"\n
  FROM\n     store_sales\n   , date_dim\n   , customer_address\n   , item\n   WHERE ("i_manufact_id"
IN (\n      SELECT "i_manufact_id"\n      FROM\n        item\n      WHERE ("i_category" IN
(\'Electronics                                       \'))\n   ))\n      AND ("ss_item_sk"
= "i_item_sk")\n      AND ("ss_sold_date_sk" = "d_date_sk")\n      AND ("d_year" = 1998)\n
     AND ("d_moy" = 5)\n      AND ("ss_addr_sk" = "ca_address_sk")\n      AND ("ca_gmt_offset"
= -5)\n   GROUP BY "i_manufact_id"\n) \n, cs AS (\n   SELECT\n     "i_manufact_id"\n   , "sum"("cs_ext_sales_price")
"total_sales"\n   FROM\n     catalog_sales\n   , date_dim\n   , customer_address\n   , item\n
  WHERE ("i_manufact_id" IN (\n      SELECT "i_manufact_id"\n      FROM\n        item\n  
   WHERE ("i_category" IN (\'Electronics                                       \'))\n   ))\n
     AND ("cs_item_sk" = "i_item_sk")\n      AND ("cs_sold_date_sk" = "d_date_sk")\n     
AND ("d_year" = 1998)\n      AND ("d_moy" = 5)\n      AND ("cs_bill_addr_sk" = "ca_address_sk")\n
     AND ("ca_gmt_offset" = -5)\n   GROUP BY "i_manufact_id"\n) \n, ws AS (\n   SELECT\n 
   "i_manufact_id"\n   , "sum"("ws_ext_sales_price") "total_sales"\n   FROM\n     web_sales\n
  , date_dim\n   , customer_address\n   , item\n   WHERE ("i_manufact_id" IN (\n      SELECT
"i_manufact_id"\n      FROM\n        item\n      WHERE ("i_category" IN (\'Electronics   
                                   \'))\n   ))\n      AND ("ws_item_sk" = "i_item_sk")\n 
    AND ("ws_sold_date_sk" = "d_date_sk")\n      AND ("d_year" = 1998)\n      AND ("d_moy"
= 5)\n      AND ("ws_bill_addr_sk" = "ca_address_sk")\n      AND ("ca_gmt_offset" = -5)\n
  GROUP BY "i_manufact_id"\n) \nSELECT\n  "i_manufact_id"\n, "sum"("total_sales") "total_sales"\nFROM\n
 (\n   SELECT *\n   FROM\n     ss\nUNION ALL    SELECT *\n   FROM\n     cs\nUNION ALL    SELECT
*\n   FROM\n     ws\n)  tmp1\nGROUP BY "i_manufact_id"\nORDER BY "total_sales" ASC\nLIMIT
100\n', u'startDttm': Decimal('1525351938199.209961'), u'limit': 1000000, u'serverId': 7,
u'resultsKey': None}
   2018-05-03 12:52:25,431:INFO:root:Fetching cursor description
   [2018-05-03 12:52:25,433] ERROR in app: Exception on /superset/sql_json/ [POST]
   Traceback (most recent call last):
     File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1982, in wsgi_app
       response = self.full_dispatch_request()
     File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1614, in full_dispatch_request
       rv = self.handle_user_exception(e)
     File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1517, in handle_user_exception
       reraise(exc_type, exc_value, tb)
     File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1612, in full_dispatch_request
       rv = self.dispatch_request()
     File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1598, in dispatch_request
       return self.view_functions[rule.endpoint](**req.view_args)
     File "/usr/local/lib/python2.7/dist-packages/flask_appbuilder/security/decorators.py",
line 52, in wraps
       return f(self, *args, **kwargs)
     File "/usr/local/lib/python2.7/dist-packages/superset/models/core.py", line 899, in wrapper
       value = f(*args, **kwargs)
     File "/usr/local/lib/python2.7/dist-packages/superset/views/core.py", line 2458, in sql_json
       if data.get('status') == QueryStatus.FAILED:
   AttributeError: 'str' object has no attribute 'get'
   Exception on /superset/sql_json/ [POST]
   Traceback (most recent call last):
     File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1982, in wsgi_app
       response = self.full_dispatch_request()
     File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1614, in full_dispatch_request
       rv = self.handle_user_exception(e)
     File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1517, in handle_user_exception
       reraise(exc_type, exc_value, tb)
     File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1612, in full_dispatch_request
       rv = self.dispatch_request()
     File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1598, in dispatch_request
       return self.view_functions[rule.endpoint](**req.view_args)
     File "/usr/local/lib/python2.7/dist-packages/flask_appbuilder/security/decorators.py",
line 52, in wraps
       return f(self, *args, **kwargs)
     File "/usr/local/lib/python2.7/dist-packages/superset/models/core.py", line 899, in wrapper
       value = f(*args, **kwargs)
     File "/usr/local/lib/python2.7/dist-packages/superset/views/core.py", line 2458, in sql_json
       if data.get('status') == QueryStatus.FAILED:
   AttributeError: 'str' object has no attribute 'get'
   ```
   
   ### Steps to reproduce
   
   1. Run long query
   2. Wait 3-6s
   3. Stop query in Superset UI
   
   My superset configuration:
   ```
   SECRET_KEY = r'1234'
   
   CACHE_CONFIG = {
       'CACHE_TYPE': 'redis',
       'CACHE_DEFAULT_TIMEOUT': 3600,
       'CACHE_KEY_PREFIX': 'superset_',
       'CACHE_REDIS_URL': 'redis://redis:6379/1',
   }
   ```
   
   Web app is run with:
   ```
   export GUNICORN_CMD_ARGS=         --bind 0.0.0.0:8088         --limit-request-field_size
0         --limit-request-line 0         --timeout 120         --worker-class gevent     
   --workers 4         "
   gunicorn superset:app
   ```
   
   

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

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


Mime
View raw message