[GitHub] maver1ck commented on issue #4355: Superset issue #4354 - Properly filter datasources

2018-02-07 Thread GitBox
maver1ck commented on issue #4355: Superset issue #4354 - Properly filter 
datasources
URL: 
https://github.com/apache/incubator-superset/pull/4355#issuecomment-364029476
 
 
   @xrmx 
   I think access_tests will be better. Looking into it.


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


With regards,
Apache Git Services


[GitHub] zyt312074545 commented on issue #4351: use enum.Enum to rewrite querystatus

2018-02-07 Thread GitBox
zyt312074545 commented on issue #4351: use enum.Enum to rewrite querystatus
URL: 
https://github.com/apache/incubator-superset/pull/4351#issuecomment-364029457
 
 
   Sorry, when I see the QueryStatus is Enum-type but it inherited from Object, 
so I think Enum is better.
   You are right. But useless 'return' needs to be deleted in line 153 in 
sql_lab.py.



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


With regards,
Apache Git Services


[GitHub] maver1ck commented on issue #4375: Smaller thumbnails - #4374

2018-02-07 Thread GitBox
maver1ck commented on issue #4375: Smaller thumbnails - #4374
URL: 
https://github.com/apache/incubator-superset/pull/4375#issuecomment-364022475
 
 
   I closed it because I created second PR.


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


With regards,
Apache Git Services


[GitHub] maver1ck closed pull request #4375: Smaller thumbnails - #4374

2018-02-07 Thread GitBox
maver1ck closed pull request #4375: Smaller thumbnails - #4374
URL: https://github.com/apache/incubator-superset/pull/4375
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/superset/assets/images/viz_small_thumbnails/area.png 
b/superset/assets/images/viz_small_thumbnails/area.png
new file mode 100644
index 00..6b2fb75d42
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/area.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/bar.png 
b/superset/assets/images/viz_small_thumbnails/bar.png
new file mode 100644
index 00..1ef2633122
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/bar.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/big_number.png 
b/superset/assets/images/viz_small_thumbnails/big_number.png
new file mode 100644
index 00..01d6da45ba
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/big_number.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/big_number_total.png 
b/superset/assets/images/viz_small_thumbnails/big_number_total.png
new file mode 100644
index 00..350d5a1ab1
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/big_number_total.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/box_plot.png 
b/superset/assets/images/viz_small_thumbnails/box_plot.png
new file mode 100644
index 00..8925e50680
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/box_plot.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/bubble.png 
b/superset/assets/images/viz_small_thumbnails/bubble.png
new file mode 100644
index 00..453388104e
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/bubble.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/bullet.png 
b/superset/assets/images/viz_small_thumbnails/bullet.png
new file mode 100644
index 00..f98c70f29b
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/bullet.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/cal_heatmap.png 
b/superset/assets/images/viz_small_thumbnails/cal_heatmap.png
new file mode 100644
index 00..c83db08ee8
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/cal_heatmap.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/chord.png 
b/superset/assets/images/viz_small_thumbnails/chord.png
new file mode 100644
index 00..18df6a72a7
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/chord.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/compare.png 
b/superset/assets/images/viz_small_thumbnails/compare.png
new file mode 100644
index 00..c17af52389
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/compare.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/country_map.png 
b/superset/assets/images/viz_small_thumbnails/country_map.png
new file mode 100644
index 00..52acbfab52
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/country_map.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/deck_arc.png 
b/superset/assets/images/viz_small_thumbnails/deck_arc.png
new file mode 100644
index 00..02b84b1e75
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/deck_arc.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/deck_geojson.png 
b/superset/assets/images/viz_small_thumbnails/deck_geojson.png
new file mode 100644
index 00..9c1a732cd5
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/deck_geojson.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/deck_grid.png 
b/superset/assets/images/viz_small_thumbnails/deck_grid.png
new file mode 100644
index 00..2710d9f128
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/deck_grid.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/deck_hex.png 
b/superset/assets/images/viz_small_thumbnails/deck_hex.png
new file mode 100644
index 00..99149dbc10
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/deck_hex.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/deck_multi.png 
b/superset/assets/images/viz_small_thumbnails/deck_multi.png
new file mode 100644
index 00..acedd5ba51
Binary files /dev/null and 
b/superset/assets/images/viz_small_thumbnails/deck_multi.png differ
diff --git a/superset/assets/images/viz_small_thumbnails/deck_path.png 
b/superset/assets/images/viz_small_thumbnails/deck_path.png
new file mode 100644
index 00..d783a14331
Binary files 

[GitHub] maver1ck commented on issue #4374: Very big visualizations' thumbnails size

2018-02-07 Thread GitBox
maver1ck commented on issue #4374: Very big visualizations' thumbnails size
URL: 
https://github.com/apache/incubator-superset/issues/4374#issuecomment-364022054
 
 
   I was thinking about it. 
   Having two sizes makes also python package 10MB bigger. 
   And it's more difficult to maintain in the future.
   I created second PR with only changed sizes. #4382
   
   PS. PNG vs JPG is 1,7 vs 1,6 MB
   


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


With regards,
Apache Git Services


[GitHub] masterlittle commented on issue #4381: [WiP] Phantom JS

2018-02-07 Thread GitBox
masterlittle commented on issue #4381: [WiP] Phantom JS
URL: 
https://github.com/apache/incubator-superset/pull/4381#issuecomment-364019511
 
 
   Can this be extended to capture screenshots of dashboard and shooting a mail 
at some intervals?


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


With regards,
Apache Git Services


[GitHub] maver1ck commented on issue #4323: Hive queries run at least 5 * some_number seconds

2018-02-07 Thread GitBox
maver1ck commented on issue #4323: Hive queries run at least 5 * some_number 
seconds 
URL: 
https://github.com/apache/incubator-superset/issues/4323#issuecomment-364017786
 
 
   Closing as PR is merged


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


With regards,
Apache Git Services


[GitHub] xiaohanyu commented on issue #4193: Init docker for local development environment.

2018-02-07 Thread GitBox
xiaohanyu commented on issue #4193: Init docker for local development 
environment.
URL: 
https://github.com/apache/incubator-superset/pull/4193#issuecomment-364017144
 
 
   @mistercrunch Agree with you about the `superset_config.py` things.
   
   About the second part, I'll do a later refactoring based on your suggestions.


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


With regards,
Apache Git Services


[GitHub] mistercrunch commented on issue #4371: Mapbox isn't working on Druid

2018-02-07 Thread GitBox
mistercrunch commented on issue #4371: Mapbox isn't working on Druid
URL: 
https://github.com/apache/incubator-superset/issues/4371#issuecomment-364012069
 
 
   Mind sharing your JSON? I'm guessing there's a reference that doesn't line 
up somehow


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


With regards,
Apache Git Services


[GitHub] mistercrunch commented on issue #4374: Very big visualizations' thumbnails size

2018-02-07 Thread GitBox
mistercrunch commented on issue #4374: Very big visualizations' thumbnails size
URL: 
https://github.com/apache/incubator-superset/issues/4374#issuecomment-364011886
 
 
   I like having the 2 different sizes.


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


With regards,
Apache Git Services


[GitHub] mistercrunch commented on issue #4376: Landing Page for Superset

2018-02-07 Thread GitBox
mistercrunch commented on issue #4376: Landing Page for Superset
URL: 
https://github.com/apache/incubator-superset/issues/4376#issuecomment-364011771
 
 
   Related: https://github.com/apache/incubator-superset/pull/4381


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


With regards,
Apache Git Services


[GitHub] mistercrunch opened a new pull request #4381: [WiP] Phantom JS

2018-02-07 Thread GitBox
mistercrunch opened a new pull request #4381: [WiP] Phantom JS
URL: https://github.com/apache/incubator-superset/pull/4381
 
 
   Did some work to get a headless browser going last april but never got to a 
perfect state. I'd say this is 60-80% done, needs a bit more TLC


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


With regards,
Apache Git Services


[GitHub] mistercrunch commented on issue #4378: [Histogram] Add default to row limit

2018-02-07 Thread GitBox
mistercrunch commented on issue #4378: [Histogram] Add default to row limit
URL: 
https://github.com/apache/incubator-superset/issues/4378#issuecomment-364010934
 
 
   fixed by https://github.com/apache/incubator-superset/pull/4372


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


With regards,
Apache Git Services


[GitHub] mistercrunch closed issue #4378: [Histogram] Add default to row limit

2018-02-07 Thread GitBox
mistercrunch closed issue #4378: [Histogram] Add default to row limit
URL: https://github.com/apache/incubator-superset/issues/4378
 
 
   


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


With regards,
Apache Git Services


[GitHub] mistercrunch commented on issue #4379: Chart stickiness - saved state

2018-02-07 Thread GitBox
mistercrunch commented on issue #4379: Chart stickiness - saved state
URL: 
https://github.com/apache/incubator-superset/issues/4379#issuecomment-364010800
 
 
   I agree it'd be nice to save the state of the legend filters in the nvd3 
charts specifically.


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


With regards,
Apache Git Services


[GitHub] mistercrunch commented on issue #4193: Init docker for local development environment.

2018-02-07 Thread GitBox
mistercrunch commented on issue #4193: Init docker for local development 
environment.
URL: 
https://github.com/apache/incubator-superset/pull/4193#issuecomment-364010237
 
 
   I'm 100% sure that `superset_config.py` shouldn't be in the main package 
though, it seems conflictual and potentially could take over another existing 
`superset_config.py` depending on PYTHONPATH or the cwd. I'm just thinking it 
would need to live somewhere else in the repo, and in the context of running in 
docker it would set the PYTHONPATH to add that folder. Maybe we can we have a 
docker subfolder in the repository?
   
   I want to make it clear to users that we don't prescribe this setup 
specifically (using docker, using py3.4, postgres over mysql, redis over 
rabbit, ...) or that this is the official/proper way of running Superset or 
whatever. I'd feel more comfortable having all this in a subfolder and adding a 
section to the installation docs "Quick Start with Docker" 


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


With regards,
Apache Git Services


[GitHub] mistercrunch commented on issue #4375: [WIP] Smaller thumbnails - #4374

2018-02-07 Thread GitBox
mistercrunch commented on issue #4375: [WIP] Smaller thumbnails - #4374
URL: 
https://github.com/apache/incubator-superset/pull/4375#issuecomment-364010337
 
 
   I see the WIP tag, let us know when this is ready to ship


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


With regards,
Apache Git Services


[GitHub] mistercrunch commented on a change in pull request #4346: Add permission checks to save_or_overwrite_slice

2018-02-07 Thread GitBox
mistercrunch commented on a change in pull request #4346: Add permission checks 
to save_or_overwrite_slice
URL: 
https://github.com/apache/incubator-superset/pull/4346#discussion_r166836344
 
 

 ##
 File path: superset/views/core.py
 ##
 @@ -1182,6 +1182,11 @@ def explore(self, datasource_type, datasource_id):
 "You don't have the rights to alter this slice",
 status=400)
 
+if action == 'saveas' and not slice_add_perm:
+return json_error_response(
+"You don't have the rights to create this slice",
 
 Review comment:
   You be great to make this translatable using `_("Translatable")`. Also we're 
moving away from `slice` in favor of `chart`.
   To minimize the number of strings to translate you may want to break it into 
chunks:
   _("You don't have the rights to ") + _("create this ") + _("slice")
   


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


With regards,
Apache Git Services


[GitHub] mistercrunch commented on issue #4375: [WIP] Smaller thumbnails - #4374

2018-02-07 Thread GitBox
mistercrunch commented on issue #4375: [WIP] Smaller thumbnails - #4374
URL: 
https://github.com/apache/incubator-superset/pull/4375#issuecomment-364006815
 
 
   jpg could be good here too, but this is already better than before


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


With regards,
Apache Git Services


[GitHub] mistercrunch opened a new pull request #4380: [error handling] 'Time Comparison' query returns no data

2018-02-07 Thread GitBox
mistercrunch opened a new pull request #4380: [error handling] 'Time 
Comparison' query returns no data
URL: https://github.com/apache/incubator-superset/pull/4380
 
 
   Will show `No data` instead of `'NoneType' object has no attribute 
'__getitem__'`


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


With regards,
Apache Git Services


[GitHub] mistercrunch closed pull request #4377: Bump pydruid to 0.4.1

2018-02-07 Thread GitBox
mistercrunch closed pull request #4377: Bump pydruid to 0.4.1
URL: https://github.com/apache/incubator-superset/pull/4377
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/setup.py b/setup.py
index 5ba4314fa7..df71d56212 100644
--- a/setup.py
+++ b/setup.py
@@ -67,7 +67,7 @@ def get_git_sha():
 'parsedatetime==2.0.0',
 'pathlib2==2.3.0',
 'polyline==1.3.2',
-'pydruid==0.4.0',
+'pydruid==0.4.1',
 'PyHive>=0.4.0',
 'python-dateutil==2.6.1',
 'pyyaml>=3.11',


 


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


With regards,
Apache Git Services


[GitHub] mistercrunch commented on issue #4377: Bump pydruid to 0.4.1

2018-02-07 Thread GitBox
mistercrunch commented on issue #4377: Bump pydruid to 0.4.1
URL: 
https://github.com/apache/incubator-superset/pull/4377#issuecomment-363959814
 
 
   )'(


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


With regards,
Apache Git Services


[GitHub] mistercrunch commented on issue #4377: Bump pydruid to 0.4.1

2018-02-07 Thread GitBox
mistercrunch commented on issue #4377: Bump pydruid to 0.4.1
URL: 
https://github.com/apache/incubator-superset/pull/4377#issuecomment-363959814
 
 
   `)'(`


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


With regards,
Apache Git Services


[GitHub] mistercrunch opened a new pull request #4377: Bump pydruid to 0.4.1

2018-02-07 Thread GitBox
mistercrunch opened a new pull request #4377: Bump pydruid to 0.4.1
URL: https://github.com/apache/incubator-superset/pull/4377
 
 
   


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


With regards,
Apache Git Services


[GitHub] vylc opened a new issue #4376: Landing Page for Superset

2018-02-07 Thread GitBox
vylc opened a new issue #4376: Landing Page for Superset
URL: https://github.com/apache/incubator-superset/issues/4376
 
 
   Improve usability and discovery by re-organizing landing page for when users 
land on Superset. With the current layout, it's hard to find what data to start 
exploring
   
   (1) Too many menus at the top - collapse administrative menus into "Manage" 
section
   (2) Make  "Search" box global
   (3) Default to a "Recently Viewed" tab that has all types of data artifacts
   (4) Card view with sample images of dashboard, chart, etc.
   
   
   https://user-images.githubusercontent.com/33429480/35947925-f4a48450-0c1e-11e8-9399-02d8096bbab2.png;>
   
   
   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
   
   
   ### Expected results
   
   
   ### Actual results
   
   
   ### Steps to reproduce
   
   
   


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


With regards,
Apache Git Services


[GitHub] mistercrunch closed pull request #4359: [revert] Reverting PR #4062

2018-02-07 Thread GitBox
mistercrunch closed pull request #4359: [revert] Reverting PR #4062
URL: https://github.com/apache/incubator-superset/pull/4359
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/superset/views/core.py b/superset/views/core.py
index 44b6b2a5a4..9aaee09ba1 100755
--- a/superset/views/core.py
+++ b/superset/views/core.py
@@ -28,7 +28,7 @@
 import sqlalchemy as sqla
 from sqlalchemy import create_engine
 from sqlalchemy.engine.url import make_url
-from sqlalchemy.exc import IntegrityError, OperationalError
+from sqlalchemy.exc import IntegrityError
 from unidecode import unidecode
 from werkzeug.routing import BaseConverter
 from werkzeug.utils import secure_filename
@@ -655,11 +655,6 @@ class LogModelView(SupersetModelView):
 
 @app.route('/health')
 def health():
-try:
-db.session.execute('SELECT 1')
-except OperationalError:
-return Response('BAD', status=500)
-
 return 'OK'
 
 


 


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


With regards,
Apache Git Services


[GitHub] mistercrunch closed pull request #4316: Fix caching related issues

2018-02-07 Thread GitBox
mistercrunch closed pull request #4316: Fix caching related issues
URL: https://github.com/apache/incubator-superset/pull/4316
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/superset/assets/package.json b/superset/assets/package.json
index c944ad2fa0..abc978c079 100644
--- a/superset/assets/package.json
+++ b/superset/assets/package.json
@@ -93,8 +93,8 @@
 "react-sortable-hoc": "^0.6.7",
 "react-split-pane": "^0.1.66",
 "react-syntax-highlighter": "^5.7.0",
-"react-virtualized": "^9.3.0",
-"react-virtualized-select": "^2.4.0",
+"react-virtualized": "9.3.0",
+"react-virtualized-select": "2.4.0",
 "reactable": "^0.14.1",
 "redux": "^3.5.2",
 "redux-localstorage": "^0.4.1",
diff --git a/superset/models/core.py b/superset/models/core.py
index 142482bdbd..cfd6d75203 100644
--- a/superset/models/core.py
+++ b/superset/models/core.py
@@ -230,7 +230,7 @@ def slice_link(self):
 name = escape(self.slice_name)
 return Markup('{name}'.format(**locals()))
 
-def get_viz(self):
+def get_viz(self, force=False):
 """Creates :py:class:viz.BaseViz object from the url_params_multidict.
 
 :return: object of the 'viz_type' type that is taken from the
@@ -246,6 +246,7 @@ def get_viz(self):
 return viz_types[slice_params.get('viz_type')](
 self.datasource,
 form_data=slice_params,
+force=force,
 )
 
 @classmethod
diff --git a/superset/views/core.py b/superset/views/core.py
index 03636db826..60990b4018 100755
--- a/superset/views/core.py
+++ b/superset/views/core.py
@@ -942,7 +942,9 @@ def get_viz(
 slice_id=None,
 form_data=None,
 datasource_type=None,
-datasource_id=None):
+datasource_id=None,
+force=False,
+):
 if slice_id:
 slc = (
 db.session.query(models.Slice)
@@ -957,6 +959,7 @@ def get_viz(
 viz_obj = viz.viz_types[viz_type](
 datasource,
 form_data=form_data,
+force=force,
 )
 return viz_obj
 
@@ -1005,7 +1008,9 @@ def generate_json(self, datasource_type, datasource_id, 
form_data,
 viz_obj = self.get_viz(
 datasource_type=datasource_type,
 datasource_id=datasource_id,
-form_data=form_data)
+form_data=form_data,
+force=force,
+)
 except Exception as e:
 logging.exception(e)
 return json_error_response(
@@ -1026,7 +1031,7 @@ def generate_json(self, datasource_type, datasource_id, 
form_data,
 return self.get_query_string_response(viz_obj)
 
 try:
-payload = viz_obj.get_payload(force=force)
+payload = viz_obj.get_payload()
 except Exception as e:
 logging.exception(e)
 return json_error_response(utils.error_msg_from_exception(e))
@@ -1070,9 +1075,10 @@ def annotation_json(self, layer_id):
 viz_obj = viz.viz_types['table'](
   datasource,
   form_data=form_data,
+  force=False,
 )
 try:
-payload = viz_obj.get_payload(force=False)
+payload = viz_obj.get_payload()
 except Exception as e:
 logging.exception(e)
 return json_error_response(utils.error_msg_from_exception(e))
@@ -1864,8 +1870,8 @@ def warm_up_cache(self):
 
 for slc in slices:
 try:
-obj = slc.get_viz()
-obj.get_json(force=True)
+obj = slc.get_viz(force=True)
+obj.get_json()
 except Exception as e:
 return json_error_response(utils.error_msg_from_exception(e))
 return json_success(json.dumps(
diff --git a/superset/viz.py b/superset/viz.py
index 6fc8cf9887..2154bcc328 100644
--- a/superset/viz.py
+++ b/superset/viz.py
@@ -18,10 +18,9 @@
 import math
 import traceback
 import uuid
-import zlib
 
 from dateutil import relativedelta as rdelta
-from flask import request
+from flask import escape, request
 from flask_babel import lazy_gettext as _
 import geohash
 from markdown import markdown
@@ -30,8 +29,8 @@
 from pandas.tseries.frequencies import to_offset
 import polyline
 import simplejson as json
-from six import PY3, string_types, text_type
-from six.moves import reduce
+from six import string_types, text_type
+from six.moves import cPickle as pkl, reduce
 
 from superset import app, cache, get_manifest_file, utils
 from superset.utils import DTTM_ALIAS, merge_extra_filters
@@ -49,8 +48,9 @@ class BaseViz(object):
 credits = ''
 is_timeseries = False
 

[GitHub] maver1ck commented on issue #4374: Very big visualizations' thumbnails size

2018-02-07 Thread GitBox
maver1ck commented on issue #4374: Very big visualizations' thumbnails size
URL: 
https://github.com/apache/incubator-superset/issues/4374#issuecomment-363934543
 
 
   #4375
   My idea is to create copy of images to use it in app.
   It's because images are also used in documentation.
   https://superset.incubator.apache.org/gallery.html
   
   If you think we can use same smaller images in documentation please let me 
know.
   I will change PR.
   


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


With regards,
Apache Git Services


[GitHub] maver1ck commented on issue #4374: Very big visualizations' thumbnails size

2018-02-07 Thread GitBox
maver1ck commented on issue #4374: Very big visualizations' thumbnails size
URL: 
https://github.com/apache/incubator-superset/issues/4374#issuecomment-363934543
 
 
   #4375
   My idea is to create copy of images to use it in app.
   It's because images are also used in documentation.
   https://superset.incubator.apache.org/gallery.html
   


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


With regards,
Apache Git Services


[GitHub] maver1ck opened a new pull request #4375: Smaller thumbnails - #4374

2018-02-07 Thread GitBox
maver1ck opened a new pull request #4375: Smaller thumbnails - #4374
URL: https://github.com/apache/incubator-superset/pull/4375
 
 
   Smaller thumbnails for Visualizations
   Drop from 11MB to 1,7MB in size


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


With regards,
Apache Git Services


[GitHub] maver1ck commented on issue #4374: Very big visualizations' thumbnails size

2018-02-07 Thread GitBox
maver1ck commented on issue #4374: Very big visualizations' thumbnails size
URL: 
https://github.com/apache/incubator-superset/issues/4374#issuecomment-363934543
 
 
   Work in progress


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


With regards,
Apache Git Services


[GitHub] mistercrunch commented on issue #4374: Very big visualizations' thumbnails size

2018-02-07 Thread GitBox
mistercrunch commented on issue #4374: Very big visualizations' thumbnails size
URL: 
https://github.com/apache/incubator-superset/issues/4374#issuecomment-363934256
 
 
   Would love if someone could contribute 512*512 jpg instead of 1024*1024 png


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


With regards,
Apache Git Services


[GitHub] mistercrunch closed pull request #4372: Set default row_limit to 50k

2018-02-07 Thread GitBox
mistercrunch closed pull request #4372: Set default row_limit to 50k
URL: https://github.com/apache/incubator-superset/pull/4372
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/superset/assets/javascripts/explore/stores/controls.jsx 
b/superset/assets/javascripts/explore/stores/controls.jsx
index dd0c6bc640..8e3420bd81 100644
--- a/superset/assets/javascripts/explore/stores/controls.jsx
+++ b/superset/assets/javascripts/explore/stores/controls.jsx
@@ -852,7 +852,7 @@ export const controls = {
 freeForm: true,
 label: t('Row limit'),
 validators: [v.integer],
-default: null,
+default: 5,
 choices: formatSelectOptions(ROW_LIMIT_OPTIONS),
   },
 


 


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


With regards,
Apache Git Services


[GitHub] mistercrunch closed pull request #4363: [line] improve "Time Shift" feature

2018-02-07 Thread GitBox
mistercrunch closed pull request #4363: [line] improve "Time Shift" feature
URL: https://github.com/apache/incubator-superset/pull/4363
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/superset/viz.py b/superset/viz.py
index 6fc8cf9887..c6d0760a8f 100644
--- a/superset/viz.py
+++ b/superset/viz.py
@@ -1070,6 +1070,11 @@ def get_data(self, df):
 delta = utils.parse_human_timedelta(time_compare)
 query_object['inner_from_dttm'] = query_object['from_dttm']
 query_object['inner_to_dttm'] = query_object['to_dttm']
+
+if not query_object['from_dttm'] or not query_object['to_dttm']:
+raise Exception(_(
+'`Since` and `Until` time bounds should be specified '
+'when using the `Time Shift` feature.'))
 query_object['from_dttm'] -= delta
 query_object['to_dttm'] -= delta
 


 


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


With regards,
Apache Git Services


[GitHub] mistercrunch closed pull request #4373: Remove dangerouslySetInnerHTML in StackTraceMessage component

2018-02-07 Thread GitBox
mistercrunch closed pull request #4373: Remove dangerouslySetInnerHTML in 
StackTraceMessage component
URL: https://github.com/apache/incubator-superset/pull/4373
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/superset/assets/javascripts/components/StackTraceMessage.jsx 
b/superset/assets/javascripts/components/StackTraceMessage.jsx
index a950c39c17..ee190b7c5c 100644
--- a/superset/assets/javascripts/components/StackTraceMessage.jsx
+++ b/superset/assets/javascripts/components/StackTraceMessage.jsx
@@ -26,20 +26,13 @@ class StackTraceMessage extends React.PureComponent {
   }
 
   render() {
-const msg = (
-  
-
-  );
-
 return (
   
  this.setState({ showStackTrace: 
!this.state.showStackTrace })}
 >
-  {msg}
+  {this.props.message}
 
 {this.hasTrace() &&
   


 


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


With regards,
Apache Git Services


[GitHub] mistercrunch closed pull request #4341: Bump python dependencies

2018-02-07 Thread GitBox
mistercrunch closed pull request #4341: Bump python dependencies
URL: https://github.com/apache/incubator-superset/pull/4341
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/setup.py b/setup.py
index 537ce10ffb..5ba4314fa7 100644
--- a/setup.py
+++ b/setup.py
@@ -49,34 +49,34 @@ def get_git_sha():
 'colorama==0.3.9',
 'cryptography==1.9',
 'flask==0.12.2',
-'flask-appbuilder==1.9.5',
+'flask-appbuilder==1.9.6',
 'flask-cache==0.13.1',
-'flask-migrate==2.0.3',
-'flask-script==2.0.5',
+'flask-migrate==2.1.1',
+'flask-script==2.0.6',
 'flask-sqlalchemy==2.1',
-'flask-testing==0.6.2',
+'flask-testing==0.7.1',
 'flask-wtf==0.14.2',
 'flower==0.9.2',
 'future>=0.16.0, <0.17',
 'python-geohash==0.8.5',
 'humanize==0.5.1',
 'gunicorn==19.7.1',
-'idna==2.5',
-'markdown==2.6.8',
-'pandas==0.20.3',
+'idna==2.6',
+'markdown==2.6.11',
+'pandas==0.22.0',
 'parsedatetime==2.0.0',
 'pathlib2==2.3.0',
 'polyline==1.3.2',
 'pydruid==0.4.0',
 'PyHive>=0.4.0',
-'python-dateutil==2.6.0',
+'python-dateutil==2.6.1',
 'pyyaml>=3.11',
-'requests==2.17.3',
-'simplejson==3.10.0',
+'requests==2.18.4',
+'simplejson==3.13.2',
 'six==1.11.0',
 'sqlalchemy==1.2.2',
 'sqlalchemy-utils==0.32.21',
-'sqlparse==0.2.3',
+'sqlparse==0.2.4',
 'thrift>=0.9.3',
 'thrift-sasl>=0.2.1',
 'unidecode>=0.04.21',


 


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


With regards,
Apache Git Services


[GitHub] hughhhh commented on issue #4373: Remove dangerouslySetInnerHTML in StackTraceMessage component

2018-02-07 Thread GitBox
hug commented on issue #4373: Remove dangerouslySetInnerHTML in 
StackTraceMessage component
URL: 
https://github.com/apache/incubator-superset/pull/4373#issuecomment-363928060
 
 
   ? 


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


With regards,
Apache Git Services


[GitHub] hughhhh commented on issue #4341: Bump python dependencies

2018-02-07 Thread GitBox
hug commented on issue #4341: Bump python dependencies
URL: 
https://github.com/apache/incubator-superset/pull/4341#issuecomment-363928253
 
 
   ? 


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


With regards,
Apache Git Services


[GitHub] hughhhh commented on issue #4363: [line] improve "Time Shift" feature

2018-02-07 Thread GitBox
hug commented on issue #4363: [line] improve "Time Shift" feature
URL: 
https://github.com/apache/incubator-superset/pull/4363#issuecomment-363927917
 
 
   ? 


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


With regards,
Apache Git Services


[GitHub] mistercrunch closed pull request #4333: Add hour grain to SQLite

2018-02-07 Thread GitBox
mistercrunch closed pull request #4333: Add hour grain to SQLite
URL: https://github.com/apache/incubator-superset/pull/4333
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/superset/data/__init__.py b/superset/data/__init__.py
index 233550cb63..e1d0b67558 100644
--- a/superset/data/__init__.py
+++ b/superset/data/__init__.py
@@ -1016,7 +1016,12 @@ def load_long_lat_data():
 """Loading lat/long data from a csv file in the repo"""
 with gzip.open(os.path.join(DATA_FOLDER, 'san_francisco.csv.gz')) as f:
 pdf = pd.read_csv(f, encoding="utf-8")
-pdf['date'] = datetime.datetime.now().date()
+start = datetime.datetime.now().replace(
+hour=0, minute=0, second=0, microsecond=0)
+pdf['datetime'] = [
+start + datetime.timedelta(hours=i * 24 / (len(pdf) - 1))
+for i in range(len(pdf))
+]
 pdf['occupancy'] = [random.randint(1, 6) for _ in range(len(pdf))]
 pdf['radius_miles'] = [random.uniform(1, 3) for _ in range(len(pdf))]
 pdf['geohash'] = pdf[['LAT', 'LON']].apply(
@@ -1038,7 +1043,7 @@ def load_long_lat_data():
 'region': String(50),
 'postcode': Float(),
 'id': String(100),
-'date': Date(),
+'datetime': DateTime(),
 'occupancy': Float(),
 'radius_miles': Float(),
 'geohash': String(12),
@@ -1052,7 +1057,7 @@ def load_long_lat_data():
 obj = db.session.query(TBL).filter_by(table_name='long_lat').first()
 if not obj:
 obj = TBL(table_name='long_lat')
-obj.main_dttm_col = 'date'
+obj.main_dttm_col = 'datetime'
 obj.database = get_or_create_main_db()
 db.session.merge(obj)
 db.session.commit()
diff --git a/superset/db_engine_specs.py b/superset/db_engine_specs.py
index d26f633bbd..8649d4fc51 100644
--- a/superset/db_engine_specs.py
+++ b/superset/db_engine_specs.py
@@ -367,6 +367,8 @@ class SqliteEngineSpec(BaseEngineSpec):
 engine = 'sqlite'
 time_grains = (
 Grain('Time Column', _('Time Column'), '{col}'),
+Grain('hour', _('hour'),
+  "DATETIME(STRFTIME('%Y-%m-%dT%H:00:00', {col}))"),
 Grain('day', _('day'), 'DATE({col})'),
 Grain('week', _('week'),
   "DATE({col}, -strftime('%w', {col}) || ' days')"),


 


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


With regards,
Apache Git Services


[GitHub] hughhhh commented on issue #4372: Set default row_limit to 50k

2018-02-07 Thread GitBox
hug commented on issue #4372: Set default row_limit to 50k
URL: 
https://github.com/apache/incubator-superset/pull/4372#issuecomment-363926913
 
 
   ? 


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


With regards,
Apache Git Services


[GitHub] maver1ck opened a new issue #4374: Very big visualization thumbnails size

2018-02-07 Thread GitBox
maver1ck opened a new issue #4374: Very big visualization thumbnails size
URL: https://github.com/apache/incubator-superset/issues/4374
 
 
   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.22.1
   
   ### Expected results
   Vizualizations' thumbnails shouldn't have more than few kb per image
   
   ### Actual results
   ```
   -rw-r--r--. 1 root root  105237 Oct 31 02:04 area.png
   -rw-r--r--. 1 root root   50564 Oct 31 02:04 bar.png
   -rw-r--r--. 1 root root   51404 Oct 31 02:04 big_number.png
   -rw-r--r--. 1 root root   27637 Oct 31 02:04 big_number_total.png
   -rw-r--r--. 1 root root   56136 Oct 31 02:04 box_plot.png
   -rw-r--r--. 1 root root  135455 Oct 31 02:04 bubble.png
   -rw-r--r--. 1 root root8764 Dec  4 23:50 bullet.png
   -rw-r--r--. 1 root root   31627 Oct 31 02:04 cal_heatmap.png
   -rw-r--r--. 1 root root  407616 Dec  4 23:50 chord.png
   -rw-r--r--. 1 root root  258894 Oct 31 02:04 compare.png
   -rw-r--r--. 1 root root  303004 Dec  4 23:50 country_map.png
   -rw-r--r--. 1 root root 2125810 Dec  4 23:50 deck_grid.png
   -rw-r--r--. 1 root root 1090997 Dec  4 23:50 deck_hex.png
   -rw-r--r--. 1 root root  795739 Dec  4 23:50 deck_scatter.png
   -rw-r--r--. 1 root root  591701 Dec  4 23:50 deck_screengrid.png
   -rw-r--r--. 1 root root  247382 Oct 31 02:04 directed_force.png
   -rw-r--r--. 1 root root   52519 Oct 31 02:04 dist_bar.png
   -rw-r--r--. 1 root root  165716 Dec  4 23:50 dual_line.png
   -rw-r--r--. 1 root root  108626 Dec  4 23:50 event_flow.png
   -rw-r--r--. 1 root root   49653 Oct 31 02:04 filter_box.png
   -rw-r--r--. 1 root root  435496 Oct 31 02:04 heatmap.png
   -rw-r--r--. 1 root root   64899 Oct 31 02:04 histogram.png
   -rw-r--r--. 1 root root  165253 Dec  4 23:50 horizon.png
   -rw-r--r--. 1 root root  755166 Oct 31 02:04 iframe.png
   -rw-r--r--. 1 root root  321509 Oct 31 02:04 line.png
   -rw-r--r--. 1 root root  225567 Oct 31 02:04 mapbox.png
   -rw-r--r--. 1 root root  227846 Oct 31 02:04 markup.png
   -rw-r--r--. 1 root root  236049 Dec  4 23:50 paired_ttest.png
   -rw-r--r--. 1 root root  471027 Oct 31 02:04 para.png
   -rw-r--r--. 1 root root  198125 Dec  4 23:50 partition.png
   -rw-r--r--. 1 root root   28302 Oct 31 02:04 pie.png
   -rw-r--r--. 1 root root  276020 Oct 31 02:04 pivot_table.png
   -rw-r--r--. 1 root root  205313 Oct 31 02:04 sankey.png
   -rw-r--r--. 1 root root  101451 Oct 31 02:04 separator.png
   -rw-r--r--. 1 root root  173806 Oct 31 02:04 sunburst.png
   -rw-r--r--. 1 root root  109326 Oct 31 02:04 table.png
   -rw-r--r--. 1 root root   84481 Dec  8 23:03 time_pivot.png
   -rw-r--r--. 1 root root   65153 Dec  4 23:50 time_table.png
   -rw-r--r--. 1 root root   96420 Oct 31 02:04 treemap.png
   -rw-r--r--. 1 root root  117846 Oct 31 02:04 word_cloud.png
   -rw-r--r--. 1 root root  136501 Oct 31 02:04 world_map.png
   ```
   For example deck_grid.png has more than 2MB.
   Whole directory has 11MB.
   
   
   


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


With regards,
Apache Git Services


[GitHub] SpyderRivera commented on issue #4371: Mapbox isn't working on Druid

2018-02-07 Thread GitBox
SpyderRivera commented on issue #4371: Mapbox isn't working on Druid
URL: 
https://github.com/apache/incubator-superset/issues/4371#issuecomment-363870773
 
 
   How could that happen? I am not able to select metrics that doesn't exist. 
Also I am using the default `COUNT(*)` metric.


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


With regards,
Apache Git Services


[GitHub] mistercrunch commented on issue #4371: Mapbox isn't working on Druid

2018-02-07 Thread GitBox
mistercrunch commented on issue #4371: Mapbox isn't working on Druid
URL: 
https://github.com/apache/incubator-superset/issues/4371#issuecomment-363862350
 
 
   Looks like a problem around handling a Druid postaggregation that references 
a metric or post agg that doesn't exist. Would be nice to handle that error 
better.


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


With regards,
Apache Git Services


[GitHub] mistercrunch opened a new pull request #4373: Remove dangerouslySetInnerHTML in StackTraceMessage component

2018-02-07 Thread GitBox
mistercrunch opened a new pull request #4373: Remove dangerouslySetInnerHTML in 
StackTraceMessage component
URL: https://github.com/apache/incubator-superset/pull/4373
 
 
   Druid sometimes returns error message that are contained in "<>", as in
   ``. Since Superset's
   approach is often to bubble up messages coming from external library,
   it's impossible to predict whether it will contain special characters.
   
   There are some cases where our error handling does return some html
   (presto?),
   but we should manage that upstream. Plus the current setup has security 
concerns,
   so let's move away from that.


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


With regards,
Apache Git Services


[GitHub] SpyderRivera commented on issue #4371: Mapbox isn't working on Druid

2018-02-07 Thread GitBox
SpyderRivera commented on issue #4371: Mapbox isn't working on Druid
URL: 
https://github.com/apache/incubator-superset/issues/4371#issuecomment-363848813
 
 
   I built from git, but I don't know exactly how to find the hash. I looked at 
my fork and the last pull from the main repo looks like 
   commit 5bc734b2e5ec4e15653f68a99d831f6a991adacf


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


With regards,
Apache Git Services


[GitHub] raffas commented on issue #4366: Add filters to dashboard in single slice without filter box view - interactive filters

2018-02-07 Thread GitBox
raffas commented on issue #4366: Add filters to dashboard in single slice 
without filter box view - interactive filters
URL: 
https://github.com/apache/incubator-superset/issues/4366#issuecomment-363831915
 
 
   If you use a Table View, you can make it filterable.
   
   If you click on a row, the other slices will be filtered using this value 
for the property associated for the cell you have selected.
   
   Otherwise, explain better the expected behaviour.


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


With regards,
Apache Git Services


[GitHub] mistercrunch opened a new pull request #4372: Set default row_limit to 50k

2018-02-07 Thread GitBox
mistercrunch opened a new pull request #4372: Set default row_limit to 50k
URL: https://github.com/apache/incubator-superset/pull/4372
 
 
   Note that users can still bump up or clear that number and effectively not 
limit the amount of data returned.


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


With regards,
Apache Git Services


[GitHub] SpyderRivera commented on issue #4371: Mapbox isn't working on Druid

2018-02-07 Thread GitBox
SpyderRivera commented on issue #4371: Mapbox isn't working on Druid
URL: 
https://github.com/apache/incubator-superset/issues/4371#issuecomment-363823781
 
 
   ![The query shouldn't be 
empty](https://user-images.githubusercontent.com/3988262/35927629-61f8b6ac-0be8-11e8-992b-7a2c582a27f5.png)
   


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


With regards,
Apache Git Services


[GitHub] xrmx commented on issue #4371: Mapbox isn't working on Druid

2018-02-07 Thread GitBox
xrmx commented on issue #4371: Mapbox isn't working on Druid
URL: 
https://github.com/apache/incubator-superset/issues/4371#issuecomment-363823874
 
 
   Is this a build from git or a release? In the first case the git hash is 
more helpful than the version written in the source.


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


With regards,
Apache Git Services


[GitHub] mistercrunch closed pull request #4358: [druid] fix bug around handling NULLs

2018-02-07 Thread GitBox
mistercrunch closed pull request #4358: [druid] fix bug around handling NULLs
URL: https://github.com/apache/incubator-superset/pull/4358
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/superset/viz.py b/superset/viz.py
index 6fc8cf9887..c50027627c 100644
--- a/superset/viz.py
+++ b/superset/viz.py
@@ -68,10 +68,10 @@ def __init__(self, datasource, form_data):
 self.status = None
 self.error_message = None
 
-def get_fillna_for_type(self, col_type):
+def get_fillna_for_col(self, col):
 """Returns the value for use as filler for a specific Column.type"""
-if col_type:
-if col_type == 'TEXT' or col_type.startswith('VARCHAR'):
+if col:
+if col.is_string:
 return ' NULL'
 return self.default_fillna
 
@@ -79,8 +79,11 @@ def get_fillna_for_columns(self, columns=None):
 """Returns a dict or scalar that can be passed to DataFrame.fillna"""
 if columns is None:
 return self.default_fillna
-columns_types = self.datasource.columns_types
-fillna = {c: self.get_fillna_for_type(columns_types.get(c)) for c in 
columns}
+columns_dict = {col.column_name: col for col in 
self.datasource.columns}
+fillna = {
+c: self.get_fillna_for_col(columns_dict.get(c))
+for c in columns
+}
 return fillna
 
 def get_df(self, query_obj=None):


 


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


With regards,
Apache Git Services


[GitHub] mistercrunch closed pull request #4368: Add ipdb to dev dependencies.

2018-02-07 Thread GitBox
mistercrunch closed pull request #4368: Add ipdb to dev dependencies.
URL: https://github.com/apache/incubator-superset/pull/4368
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/dev-reqs.txt b/dev-reqs.txt
index 0705bd2da4..91a74d6a44 100644
--- a/dev-reqs.txt
+++ b/dev-reqs.txt
@@ -2,6 +2,7 @@ codeclimate-test-reporter
 coveralls
 flake8
 flask_cors
+ipdb
 mock
 mysqlclient
 nose


 


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


With regards,
Apache Git Services


[GitHub] mistercrunch closed pull request #4319: convert postgresql date_trunc() to UTC to prevent pandas error

2018-02-07 Thread GitBox
mistercrunch closed pull request #4319: convert postgresql date_trunc() to UTC 
to prevent pandas error
URL: https://github.com/apache/incubator-superset/pull/4319
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/superset/db_engine_specs.py b/superset/db_engine_specs.py
index d26f633bbd..f46e91571c 100644
--- a/superset/db_engine_specs.py
+++ b/superset/db_engine_specs.py
@@ -285,14 +285,22 @@ class PostgresEngineSpec(BaseEngineSpec):
 
 time_grains = (
 Grain('Time Column', _('Time Column'), '{col}'),
-Grain('second', _('second'), "DATE_TRUNC('second', {col})"),
-Grain('minute', _('minute'), "DATE_TRUNC('minute', {col})"),
-Grain('hour', _('hour'), "DATE_TRUNC('hour', {col})"),
-Grain('day', _('day'), "DATE_TRUNC('day', {col})"),
-Grain('week', _('week'), "DATE_TRUNC('week', {col})"),
-Grain('month', _('month'), "DATE_TRUNC('month', {col})"),
-Grain('quarter', _('quarter'), "DATE_TRUNC('quarter', {col})"),
-Grain('year', _('year'), "DATE_TRUNC('year', {col})"),
+Grain('second', _('second'),
+  "DATE_TRUNC('second', {col}) AT TIME ZONE 'UTC'"),
+Grain('minute', _('minute'),
+  "DATE_TRUNC('minute', {col}) AT TIME ZONE 'UTC'"),
+Grain('hour', _('hour'),
+  "DATE_TRUNC('hour', {col}) AT TIME ZONE 'UTC'"),
+Grain('day', _('day'),
+  "DATE_TRUNC('day', {col}) AT TIME ZONE 'UTC'"),
+Grain('week', _('week'),
+  "DATE_TRUNC('week', {col}) AT TIME ZONE 'UTC'"),
+Grain('month', _('month'),
+  "DATE_TRUNC('month', {col}) AT TIME ZONE 'UTC'"),
+Grain('quarter', _('quarter'),
+  "DATE_TRUNC('quarter', {col}) AT TIME ZONE 'UTC'"),
+Grain('year', _('year'),
+  "DATE_TRUNC('year', {col}) AT TIME ZONE 'UTC'"),
 )
 
 @classmethod


 


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


With regards,
Apache Git Services


[GitHub] mistercrunch commented on issue #2873: Connecting Superset to Kerberized Hive with Pyhive

2018-02-07 Thread GitBox
mistercrunch commented on issue #2873: Connecting Superset to Kerberized Hive 
with Pyhive
URL: 
https://github.com/apache/incubator-superset/issues/2873#issuecomment-363821816
 
 
   MR Hive just because it's so slow. Haven't used LLAP Hive.


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


With regards,
Apache Git Services


[GitHub] mistercrunch commented on issue #2873: Connecting Superset to Kerberized Hive with Pyhive

2018-02-07 Thread GitBox
mistercrunch commented on issue #2873: Connecting Superset to Kerberized Hive 
with Pyhive
URL: 
https://github.com/apache/incubator-superset/issues/2873#issuecomment-363821816
 
 
   MR Hive. Haven't used LLAP Hive.


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


With regards,
Apache Git Services


[GitHub] SpyderRivera opened a new issue #4371: Mapbox isn't working on Druid

2018-02-07 Thread GitBox
SpyderRivera opened a new issue #4371: Mapbox isn't working on Druid
URL: https://github.com/apache/incubator-superset/issues/4371
 
 
   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
   - [ ] 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.21
   
   ### Expected results
   A map
   
   ### Actual results
   `Traceback (most recent call last):
 File 
"/home/mtraylor/venv/lib/python2.7/site-packages/superset-0.21.0rc1-py2.7.egg/superset/viz.py",
 line 276, in get_payload
   df = self.get_df()
 File 
"/home/mtraylor/venv/lib/python2.7/site-packages/superset-0.21.0rc1-py2.7.egg/superset/viz.py",
 line 98, in get_df
   self.results = self.datasource.query(query_obj)
 File 
"/home/mtraylor/venv/lib/python2.7/site-packages/superset-0.21.0rc1-py2.7.egg/superset/connectors/druid/models.py",
 line 1145, in query
   client=client, query_obj=query_obj, phase=2)
 File 
"/home/mtraylor/venv/lib/python2.7/site-packages/superset-0.21.0rc1-py2.7.egg/superset/connectors/druid/models.py",
 line 933, in get_query_str
   return self.run_query(client=client, phase=phase, **query_obj)
 File 
"/home/mtraylor/venv/lib/python2.7/site-packages/superset-0.21.0rc1-py2.7.egg/superset/connectors/druid/models.py",
 line 995, in run_query
   metrics_dict)
 File 
"/home/mtraylor/venv/lib/python2.7/site-packages/superset-0.21.0rc1-py2.7.egg/superset/connectors/druid/models.py",
 line 892, in metrics_and_post_aggs
   if metrics_dict[metric_name].metric_type != 'postagg':
   KeyError: None`
   
   ### Steps to reproduce
   
   Choose World Map as the viz type. Select the dimension containing the 
country code (in my case ISO alpha 2).
   


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


With regards,
Apache Git Services


[GitHub] mistercrunch closed pull request #4367: Remove useless empty npm-debug.log

2018-02-07 Thread GitBox
mistercrunch closed pull request #4367: Remove useless empty npm-debug.log
URL: https://github.com/apache/incubator-superset/pull/4367
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/.gitignore b/.gitignore
index df190c8abe..bc7d7e8272 100644
--- a/.gitignore
+++ b/.gitignore
@@ -31,7 +31,7 @@ app.db
 *.entry.js
 *.js.map
 node_modules
-npm-debug.log
+npm-debug.log*
 yarn.lock
 superset/assets/version_info.json
 
diff --git a/superset/assets/npm-debug.log.3344327073 
b/superset/assets/npm-debug.log.3344327073
deleted file mode 100644
index e69de29bb2..00


 


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


With regards,
Apache Git Services


[GitHub] maver1ck opened a new issue #4370: Two user profile pages - let's make it one

2018-02-07 Thread GitBox
maver1ck opened a new issue #4370: Two user profile pages - let's make it one
URL: https://github.com/apache/incubator-superset/issues/4370
 
 
   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.22.1
   
   ### Expected results
   I'd like to have:
   - one user profile page
   - welcome page when clicking on Superset logo
   
   ### Actual results
   There is two profile pages:
   1) when clicking on superset logo:
   /superset/profile/admin/
   2) when clicking on user icon / profile
   /users/userinfo/
   
   What's the recommendation ?
   
   


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


With regards,
Apache Git Services


[GitHub] lexrf commented on issue #4356: Timestamp from Kylin become 1970/01/01...

2018-02-07 Thread GitBox
lexrf commented on issue #4356: Timestamp from Kylin become 1970/01/01...
URL: 
https://github.com/apache/incubator-superset/issues/4356#issuecomment-363760133
 
 
   I debugged the code and found the problem happens in viz.py 114-122
   
   if DTTM_ALIAS in df.columns:
   if timestamp_format in ('epoch_s', 'epoch_ms'):
   df[DTTM_ALIAS] = pd.to_datetime(df[DTTM_ALIAS], 
utc=False)
   else:
   df[DTTM_ALIAS] = pd.to_datetime(
   df[DTTM_ALIAS], utc=False, format=timestamp_format)
   if self.datasource.offset:
   df[DTTM_ALIAS] += timedelta(hours=self.datasource.offset)
   
   it use pandas.to_datetime to convert the timestamp value to datetime format. 
However, by default the to_datetime function us ns as original time unit. And 
the query result is in second. This make time value * 10e-9 after convert.
   
   Surperset should use some code to determine the timestamp unit.
   
   


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


With regards,
Apache Git Services


[GitHub] xiaohanyu commented on issue #3416: Add ability to color cells on Pivot Tables

2018-02-07 Thread GitBox
xiaohanyu commented on issue #3416: Add ability to color cells on Pivot Tables
URL: 
https://github.com/apache/incubator-superset/issues/3416#issuecomment-363745069
 
 
   We're almost done.
   
   @WangXueminGit is really working quite hard on this feature and after 
internal code review, we'll push this to upstream soon.
   
   Here's a small demo of our work:
   
   ![ezgif 
com-resize](https://user-images.githubusercontent.com/1164623/35914802-9a8c8442-0c3f-11e8-8806-6639c5a1b77d.gif)
   


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


With regards,
Apache Git Services


[GitHub] xiaohanyu commented on issue #3416: Add ability to color cells on Pivot Tables

2018-02-07 Thread GitBox
xiaohanyu commented on issue #3416: Add ability to color cells on Pivot Tables
URL: 
https://github.com/apache/incubator-superset/issues/3416#issuecomment-363745069
 
 
   We're almost done.
   
   @WangXueminGit is really working quite hard on this feature and after 
internal code review, we'll push this to upstream.
   
   Here's a small demo of our work:
   
   ![ezgif 
com-resize](https://user-images.githubusercontent.com/1164623/35914802-9a8c8442-0c3f-11e8-8806-6639c5a1b77d.gif)
   


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


With regards,
Apache Git Services


[GitHub] SanjayJosh commented on issue #2873: Connecting Superset to Kerberized Hive with Pyhive

2018-02-07 Thread GitBox
SanjayJosh commented on issue #2873: Connecting Superset to Kerberized Hive 
with Pyhive
URL: 
https://github.com/apache/incubator-superset/issues/2873#issuecomment-363713503
 
 
   @mistercrunch . When you say Hive doesn't provide a good experience with 
Superset, do you mean the native MapReduce or the Hive LLAP ?


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


With regards,
Apache Git Services


[GitHub] tony0918 opened a new issue #4369: Big blank margin for dist_bar viz

2018-02-07 Thread GitBox
tony0918 opened a new issue #4369: Big blank margin for dist_bar viz
URL: https://github.com/apache/incubator-superset/issues/4369
 
 
   Make sure these boxes are checked before submitting your issue - thank you!
   
   - [ ] I have checked the superset logs for python stacktraces and included 
it here as text if any
   - [ ] I have reproduced the issue with at least the latest released version 
of superset
   - [ ] I have checked the issue tracker for the same issue and I haven't 
found one similar
   
   
   ### Superset version
   0.22.1
   
   ### Expected results
   The chart should be closed to the edge of the wrapper
   
   ### Actual results
   There is a huge blank margin between chart and wrapper.
   
   ### Steps to reproduce
   
![image](https://user-images.githubusercontent.com/584805/35909032-4d766c8e-0c2d-11e8-9905-74f7cf313bf3.png)
   
   
   


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


With regards,
Apache Git Services


[GitHub] habalux commented on issue #4319: convert postgresql date_trunc() to UTC to prevent pandas error

2018-02-07 Thread GitBox
habalux commented on issue #4319: convert postgresql date_trunc() to UTC to 
prevent pandas error
URL: 
https://github.com/apache/incubator-superset/pull/4319#issuecomment-363704684
 
 
   I ran some more tests of my own, and it seems that just converting to UTC 
will cause invalid times with the type "timestamp without time zone" as it adds 
the current (session) timezone to the timestamp. It also swaps the return type 
so "timestamp without time zone" becomes "timestamp with time zone" and vice 
versa.
   
   I found that the most consistent approach would be to use "SET TIMEZONE to 
'UTC';" at the start of a connection and then casting to "timestamp without 
time zone". This way all returned timestamps would be in UTC. Couldn't find a 
proper place to set a query to run at connection time though, any pointers? 
Also this would then require the UI to handle TZ conversions when rendering the 
data.


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


With regards,
Apache Git Services


[GitHub] xiaohanyu opened a new pull request #4368: Add ipdb to dev dependencies.

2018-02-07 Thread GitBox
xiaohanyu opened a new pull request #4368: Add ipdb to dev dependencies.
URL: https://github.com/apache/incubator-superset/pull/4368
 
 
   Though flask has a builtin web debugger, ipdb some times still work
   better. So I think add ipdb to dev dependencies is a good option for
   people who prefer CLI debugging.


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


With regards,
Apache Git Services