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 2020/07/01 08:54:58 UTC

[GitHub] [incubator-superset] shashisingh opened a new issue #10215: Explore option in viz shows "Empty Query" error

shashisingh opened a new issue #10215:
URL: https://github.com/apache/incubator-superset/issues/10215


   I built docker image from the code in master branch. I followed following steps to build and start docker container.
   
   1) docker build -f superset:test -f Dockerfile . 
   2) docker run -d -p 10088:8080 -v /home/ubuntu/ssConfig:/app/pythonpath --health-cmd='curl -f localhost:8080' --name superset_test superset:test 
   3) docker exec -it superset_test superset fab create-admin --username admin --firstname Superset --lastname Admin --email admin@superset.com --password XXXXX 
   4) docker exec -it superset_test superset db upgrade 
   5) docker exec -it superset_test superset init
   
   /home/ubuntu/ssConfig -> contains superset_config.py where I set DRUID_IS_ACTIVE to True and SQLALCHEMY_DATABASE_URI pointing to a postgres database.
   
   After this I created a database that is setup to query druid broker. I input a group by query similar to the following -> SELECT eventId , eventType, COUNT(*) as counter FROM "druid_datasource_name" GROUP BY("eventId","eventType"); I can see the results in SQLTab. I clicked on "Explore"  option to open visualization window.
   
   ### Expected results
   
   I should see a table displayed in the visualization area.
   
   ### Actual results
   
   I see an error that says "Empty query?". 
   
   Stack Trace is shown below ---
   Exception: Empty query?  
   ERROR:superset.viz:Empty query?  
   Traceback (most recent call last):  
   File "/usr/local/lib/python3.6/site-packages/superset/viz.py", line 463, in get_df_payload  
   df = self.get_df(query_obj)  
   File "/usr/local/lib/python3.6/site-packages/superset/viz.py", line 240, in get_df  
   self.results = self.datasource.query(query_obj)  
   File "/usr/local/lib/python3.6/site-packages/superset/connectors/sqla/models.py", line 1128, in query  
   query_str_ext = self.get_query_str_extended(query_obj)  
   File "/usr/local/lib/python3.6/site-packages/superset/connectors/sqla/models.py", line 655, in get_query_str_extended  
   sqlaq = self.get_sqla_query(**query_obj)  
   File "/usr/local/lib/python3.6/site-packages/superset/connectors/sqla/models.py", line 798, in get_sqla_query  
   raise Exception(_("Empty query?"))  
   Exception: Empty query?
   
   ### Environment
   
   
   Environment
   • superset version: 0.999.0dev
   • python version: 3.6.10
   • node.js version: 13.6.0
   • npm version: 6.13.4
   
   ### Checklist
   
   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 there are 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.
   
   


----------------------------------------------------------------
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.

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


[GitHub] [incubator-superset] dpgaspar commented on issue #10215: Explore option in viz shows "Empty Query" error

Posted by GitBox <gi...@apache.org>.
dpgaspar commented on issue #10215:
URL: https://github.com/apache/incubator-superset/issues/10215#issuecomment-652360379


   ups! sorry for that @shashanksingh
   


----------------------------------------------------------------
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.

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


[GitHub] [incubator-superset] issue-label-bot[bot] commented on issue #10215: Explore option in viz shows "Empty Query" error

Posted by GitBox <gi...@apache.org>.
issue-label-bot[bot] commented on issue #10215:
URL: https://github.com/apache/incubator-superset/issues/10215#issuecomment-652288018


   Issue-Label Bot is automatically applying the label `#bug` to this issue, with a confidence of 0.64. Please mark this comment with :thumbsup: or :thumbsdown: to give our bot feedback! 
   
    Links: [app homepage](https://github.com/marketplace/issue-label-bot), [dashboard](https://mlbot.net/data/apache/incubator-superset) and [code](https://github.com/hamelsmu/MLapp) for this bot.


----------------------------------------------------------------
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.

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


[GitHub] [incubator-superset] ktmud commented on issue #10215: Explore option in viz shows "Empty Query" error

Posted by GitBox <gi...@apache.org>.
ktmud commented on issue #10215:
URL: https://github.com/apache/incubator-superset/issues/10215#issuecomment-652559601


   Fixed by apache-superset/superset-ui#659 and #10219. Sorry for the inconvenience.


----------------------------------------------------------------
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.

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


[GitHub] [incubator-superset] shashanksingh commented on issue #10215: Explore option in viz shows "Empty Query" error

Posted by GitBox <gi...@apache.org>.
shashanksingh commented on issue #10215:
URL: https://github.com/apache/incubator-superset/issues/10215#issuecomment-652351793


   @dpgaspar thanks for that man, but I think the reporter, @shashisingh is a different human being :D


----------------------------------------------------------------
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.

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


[GitHub] [incubator-superset] ktmud closed issue #10215: Explore option in viz shows "Empty Query" error

Posted by GitBox <gi...@apache.org>.
ktmud closed issue #10215:
URL: https://github.com/apache/incubator-superset/issues/10215


   


----------------------------------------------------------------
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.

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


[GitHub] [incubator-superset] dpgaspar commented on issue #10215: Explore option in viz shows "Empty Query" error

Posted by GitBox <gi...@apache.org>.
dpgaspar commented on issue #10215:
URL: https://github.com/apache/incubator-superset/issues/10215#issuecomment-652333803


   Hi @shashanksingh,
   
   Thank you for taking the time to report this issue. I'm able to reproduce.
   
   Investigating


----------------------------------------------------------------
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.

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


[GitHub] [incubator-superset] dpgaspar edited a comment on issue #10215: Explore option in viz shows "Empty Query" error

Posted by GitBox <gi...@apache.org>.
dpgaspar edited a comment on issue #10215:
URL: https://github.com/apache/incubator-superset/issues/10215#issuecomment-652416545


   I think this was introduced here: #10113, still investigating
   
   Seems like that when using explore from SQLLab we have this issue, but if we explore from the datasets list view using the created virtual dataset the charts render correctly
   
   from SQLLab:
   expore_json/ returns 400
   
   form_data:
   ```
   {"queryFields":{"groupby":"groupby","metrics":"metrics"},"datasource":"37__table","viz_type":"table","time_range_endpoints":["inclusive","exclusive"],"granularity_sqla":"last_login","time_grain_sqla":"P1D","time_range":"No filter","query_mode":"aggregate","groupby":[],"metrics":[],"all_columns":["id","first_name","last_name","username","password","active","email","last_login","login_count","fail_login_count","created_on","changed_on","created_by_fk","changed_by_fk"],"percent_metrics":[],"timeseries_limit_metric":null,"order_by_cols":[],"row_limit":1000,"include_time":false,"order_desc":true,"adhoc_filters":[],"table_timestamp_format":"smart_date","page_length":null,"include_search":false,"table_filter":false,"align_pn":false,"color_pn":true,"show_cell_bars":true}
   ```
   
   from datasets list:
   ```
   {"queryFields":{"groupby":"groupby","metrics":"metrics"},"datasource":"37__table","viz_type":"table","url_params":{},"time_range_endpoints":["inclusive","exclusive"],"granularity_sqla":"last_login","time_grain_sqla":"P1D","time_range":"Last week","query_mode":"aggregate","groupby":[],"metrics":["count"],"all_columns":[],"percent_metrics":[],"timeseries_limit_metric":null,"order_by_cols":[],"row_limit":10000,"include_time":false,"order_desc":true,"adhoc_filters":[],"table_timestamp_format":"smart_date","page_length":null,"include_search":false,"table_filter":false,"align_pn":false,"color_pn":true,"show_cell_bars":true}
   ```
   
   missing the "metrics":["count"]
   
   


----------------------------------------------------------------
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.

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


[GitHub] [incubator-superset] dpgaspar edited a comment on issue #10215: Explore option in viz shows "Empty Query" error

Posted by GitBox <gi...@apache.org>.
dpgaspar edited a comment on issue #10215:
URL: https://github.com/apache/incubator-superset/issues/10215#issuecomment-652416545


   I think this was introduced here: #10113, still investigating
   
   Seems like that when using explore from SQLLab we have this issue, but if we explore from the datasets list view using the created virtual dataset the charts render correctly
   
   from SQLLab:
   expore_json/ returns 400
   
   form_data:
   ```
   {"queryFields":{"groupby":"groupby","metrics":"metrics"},"datasource":"37__table","viz_type":"table","time_range_endpoints":["inclusive","exclusive"],"granularity_sqla":"last_login","time_grain_sqla":"P1D","time_range":"No filter","query_mode":"aggregate","groupby":[],"metrics":[],"all_columns":["id","first_name","last_name","username","password","active","email","last_login","login_count","fail_login_count","created_on","changed_on","created_by_fk","changed_by_fk"],"percent_metrics":[],"timeseries_limit_metric":null,"order_by_cols":[],"row_limit":1000,"include_time":false,"order_desc":true,"adhoc_filters":[],"table_timestamp_format":"smart_date","page_length":null,"include_search":false,"table_filter":false,"align_pn":false,"color_pn":true,"show_cell_bars":true}
   ```
   
   from datasets list:
   ```
   {"queryFields":{"groupby":"groupby","metrics":"metrics"},"datasource":"37__table","viz_type":"table","url_params":{},"time_range_endpoints":["inclusive","exclusive"],"granularity_sqla":"last_login","time_grain_sqla":"P1D","time_range":"Last week","query_mode":"aggregate","groupby":[],"metrics":["count"],"all_columns":[],"percent_metrics":[],"timeseries_limit_metric":null,"order_by_cols":[],"row_limit":10000,"include_time":false,"order_desc":true,"adhoc_filters":[],"table_timestamp_format":"smart_date","page_length":null,"include_search":false,"table_filter":false,"align_pn":false,"color_pn":true,"show_cell_bars":true}
   ```
   
   missing the "metrics":["count"] on the first request
   
   @ktmud can you take a look?


----------------------------------------------------------------
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.

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


[GitHub] [incubator-superset] dpgaspar edited a comment on issue #10215: Explore option in viz shows "Empty Query" error

Posted by GitBox <gi...@apache.org>.
dpgaspar edited a comment on issue #10215:
URL: https://github.com/apache/incubator-superset/issues/10215#issuecomment-652416545


   I think this was introduced here: #10113, still investigating
   
   Seems like that when using explore from SQLLab we have this issue, but if we explore from the datasets list view using the created virtual dataset the charts render correctly
   
   from SQLLab:
   expore_json/ returns 400
   
   form_data:
   ```
   {"queryFields":{"groupby":"groupby","metrics":"metrics"},"datasource":"37__table","viz_type":"table","time_range_endpoints":["inclusive","exclusive"],"granularity_sqla":"last_login","time_grain_sqla":"P1D","time_range":"No filter","query_mode":"aggregate","groupby":[],"metrics":[],"all_columns":["id","first_name","last_name","username","password","active","email","last_login","login_count","fail_login_count","created_on","changed_on","created_by_fk","changed_by_fk"],"percent_metrics":[],"timeseries_limit_metric":null,"order_by_cols":[],"row_limit":1000,"include_time":false,"order_desc":true,"adhoc_filters":[],"table_timestamp_format":"smart_date","page_length":null,"include_search":false,"table_filter":false,"align_pn":false,"color_pn":true,"show_cell_bars":true}
   ```
   
   from datasets list:
   ```
   {"queryFields":{"groupby":"groupby","metrics":"metrics"},"datasource":"37__table","viz_type":"table","url_params":{},"time_range_endpoints":["inclusive","exclusive"],"granularity_sqla":"last_login","time_grain_sqla":"P1D","time_range":"Last week","query_mode":"aggregate","groupby":[],"metrics":["count"],"all_columns":[],"percent_metrics":[],"timeseries_limit_metric":null,"order_by_cols":[],"row_limit":10000,"include_time":false,"order_desc":true,"adhoc_filters":[],"table_timestamp_format":"smart_date","page_length":null,"include_search":false,"table_filter":false,"align_pn":false,"color_pn":true,"show_cell_bars":true}
   ```
   
   missing the "metrics":["count"] on the first request
   
   


----------------------------------------------------------------
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.

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


[GitHub] [incubator-superset] dpgaspar commented on issue #10215: Explore option in viz shows "Empty Query" error

Posted by GitBox <gi...@apache.org>.
dpgaspar commented on issue #10215:
URL: https://github.com/apache/incubator-superset/issues/10215#issuecomment-652416545


   I think this was introduced here: #10113, still investigating


----------------------------------------------------------------
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.

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