Compare commits

..

257 Commits

Author SHA1 Message Date
Maxime Beauchemin
dd6f107902 0.24.0rc1 2018-03-19 13:42:40 -07:00
michellethomas
5c98f5642b Fix sqllab numpy array (#4629)
* Fixing error with sqllab numpy array

* Adding tests for failing sqllab data type
2018-03-19 11:43:04 -07:00
Beto Dealmeida
ba9379b949 Only show overlay if container is set (#4601)
* Pass width in props

* Only load overlay if container is set
2018-03-19 11:23:19 -07:00
Maxime Beauchemin
83f8f98ae3 [cosmetic] removing table border in ModelView list (#4638) 2018-03-19 11:02:40 -07:00
Hugh A. Miles II
e9b5b1a305 part1 (#4641) 2018-03-19 11:02:03 -07:00
michellethomas
97afcd5809 Adding to list of generated-members to fix pylint errors (#4632)
* Adding to list of generated-members

* Updating to ignore-classes sqlalchemy scoped_session
2018-03-16 16:20:25 -07:00
michellethomas
3f1dfb3173 Adding column type label to dropdowns (#4566)
* Adding column type label to dropdowns

* Changing the style of column type label

* Adding tests for ColumnTypeLabel

* Adding tests for time and fixing if statement order

* Changing location of ColumnTypeLabel tests

* Updating ColumnTypeLabel structure
2018-03-16 14:19:09 -07:00
John Bodley
6875868cf6 Merge pull request #4627 from mistercrunch/fix_run_extra
Move run_extra_queries outsize of BaseViz init
2018-03-16 13:21:57 -07:00
Maxime Beauchemin
b906fece68 Move run_extra_queries outsize of BaseViz init 2018-03-16 10:05:15 -07:00
Maxime Beauchemin
93ec76f757 [sql lab] reduce the number of metadata calls when loading a table (#4593) 2018-03-15 17:53:34 -07:00
Beto Dealmeida
da842f113a Fix function name (#4620) 2018-03-15 17:52:30 -07:00
Beto Dealmeida
7da164d386 Remove group by from deck.gl viz (#4622) 2018-03-15 17:48:18 -07:00
Maxime Beauchemin
1e0bcba568 Allowing config flag to turn off flask-compress (#4617) 2018-03-15 17:17:04 -07:00
Chris Williams
e2bd40c89f [bug fixes] annotations <> x domains, zeros in text (#4194)
* [bugs] account for annotations in nvd3 x scale domain, fix dynamic width explore charts, allow 0 in text control

* tweak TextControl casting

* [annotations] filter separately from finding data extent
2018-03-15 15:13:24 -07:00
Grace Guo
7c5bc8d90c fix mapbox viz (#4621) 2018-03-15 15:06:41 -07:00
John Bodley
36fa6cd7df [contributing] Removing obsolete code climate reference (#4616) 2018-03-14 16:50:25 -07:00
Beto Dealmeida
7089344623 Legend for deck.gl scatterplot (#4572)
* Initial work

* Working version

* Specify legend position

* Max height with scroll

* Fix lint

* Better compatibility with nvd3

* Fix object.keys polyfill version

* Fix lint
2018-03-14 16:40:14 -07:00
Beto Dealmeida
86a03d1dc8 Show "Range Filter" by default (#4604)
* Show Range Filter by default

* Auto show brush

* Backwards compat

* Small fix
2018-03-14 16:38:47 -07:00
Gabe Lyons
3371c8bd5c overriding annotation and layers' control tab (#4609) 2018-03-14 00:05:06 -07:00
Chris Williams
95a9b046f8 [slice_json] pass slice id to get_form_data() (#4607) 2018-03-13 14:49:06 -07:00
John Bodley
4250e239a2 Merge pull request #4590 from michellethomas/fixing_double_escape_presto
Removing escape_sql so we dont double escape
2018-03-13 12:19:44 -07:00
John Bodley
4e494b264b Merge pull request #4579 from michellethomas/removing_title_label
Removing [dashboard] and [slice] titles to show name
2018-03-13 12:00:11 -07:00
John Bodley
de4409835e Merge pull request #4573 from john-bodley/john-bodley-cache-fix-datasource-uid
[cache] Ensuring that the datasource UID is defined
2018-03-13 10:55:40 -07:00
John Bodley
037c04102f Merge pull request #4602 from john-bodley/john-bodley-druid-sync-fix-filter
[druid] Adding cluster filter for refresh
2018-03-13 10:53:36 -07:00
michellethomas
1d0ec9fe6e timeseries_limit should not be required for phase 2 (#4581) 2018-03-13 09:25:14 -07:00
Michelle Thomas
882921825c Changing the title for explore pages 2018-03-12 17:59:49 -07:00
John Bodley
9604e1dd14 [druid] Adding cluster filter for refresh 2018-03-12 16:23:08 -07:00
oxydash
8951990d6e [BugFix] Resizing widgets problem #4596 (#4597) 2018-03-12 14:27:02 -07:00
John Bodley
26257d94f5 [cache] Ensuring that the datasource UID is defined 2018-03-12 09:49:32 -07:00
Hugh A. Miles II
2bc089ef8d Added new exception class and start of better exception/error handling (#4514)
* rebase and linting

* change back

* wip

* fixed broken test

* fix flake8

* fix test
2018-03-11 22:07:51 -07:00
oxydash
ff41f40721 Add ignore git @eaDir Synology directory (#4599) 2018-03-11 21:54:49 -07:00
Ville Brofeldt
ee073eee23 Add Aktia Bank in organizations list who use Superset (#4591)
PRs and #4413 and #4448 contributed while implementing Superset at Aktia.
2018-03-11 11:45:47 -07:00
Riccardo Magliocchetti
1d27fb30ff docs: fixup code blocks rendering (#4594) 2018-03-11 11:34:58 -07:00
Michelle Thomas
e1af421f0c Removing escape_sql so we dont double escape 2018-03-09 15:37:17 -08:00
Riccardo Magliocchetti
f9881101ee histograms: fixup left margin assigment (#4532) 2018-03-09 15:31:34 -08:00
Beto Dealmeida
1647004486 Return __time in Druid scan (#4504)
* Return __time in Druid scan

* use constant instead of __timestamp

* Fix lint
2018-03-09 15:28:11 -08:00
Hugh A. Miles II
c6af4882cd [sqllab] Added share button to bottom menu (#4584)
* added sharebtn

* address comments
2018-03-09 15:10:36 -08:00
Maxime Beauchemin
d522292b01 [sql lab] option to disable cross schema search (#4551)
* [sql lab] disable cross schema search

This is killing our metastore as people type it emits large
all-table-dump as they hit the keystroke. It never returns as it times
out and hammers the poor metastore.

Also some improvements around the disabling the table select on the left
panel and having the table name not be sticky.

* typo
2018-03-09 14:54:39 -08:00
Maxime Beauchemin
34a081b926 [sql lab] comment injection hook (#4585) 2018-03-09 11:27:36 -08:00
oxydash
4ffc56f1c9 [Translate] Added Full Russian Translation (#4586) 2018-03-09 11:13:37 -08:00
John Bodley
c85eea3037 Merge pull request #4582 from john-bodley/john-bodley-javascript-codecov
[code-climate] Deprecating Code Climate from JavaScript tests
2018-03-09 09:02:14 -08:00
John Bodley
3fbadd68a4 [code-climate] Deprecating Code Climate from JavaScript tests 2018-03-08 22:40:08 -08:00
Pithawat Vachiramon
b512da8002 Adding option to visualize negative values in Table view (#4570)
* Adding option to visualize negative values in Table view

* Adding option for highlighting and right aligning

* Fixed typo

* Fixed case and condition

* Formatting

* Aligning left and default changes

* Changing default
2018-03-08 18:07:49 -08:00
Michelle Thomas
402c7ddb26 Removing [dashboard] and [slice] titles to show name 2018-03-08 13:55:00 -08:00
Grace Guo
9edbd64c5d [Explore] Save custom url parameters when user save slices (#4578)
* [Explore] Save url parameters when user save slices

* remove print

(cherry picked from commit bd9ecbe)

* add unit test

(cherry picked from commit 0f350ad)

* wrapping all request params into url_params

(cherry picked from commit 17197c1)
2018-03-08 13:19:41 -08:00
EvelynTurner
42ebcaad40 Evelynturner/annotation timezone fix2 (#4550)
* Fix how the annotation layer interpretes the timestamp string without timezone info; use it as UTC

* Fix how the Interval annotation layer interpretes the timestamp string without timezone info; use it as UTC
2018-03-08 10:19:36 -08:00
André Neidert
9ad50c9d55 Basic Portuguese Brazilian Translation (#4472)
* Basic Portuguese Brazilian Translation

* removing incorrect indentation

* Correct language name

* Improving language description

* Improving flag description
2018-03-07 17:43:55 -08:00
Kyle Travis
31a995714d [bug] Fix CSV upload feature for DB with password (#4562)
* Use sqlalchemy_uri_decrypted in create_engine calls

* Update tox mysql uri

* Include mysql charset=utf8 for py2.7 in tox.ini
2018-03-07 17:42:52 -08:00
John Bodley
d494c82930 [landscape.io] Deprecating .landscape.yml (#4563) 2018-03-07 17:40:23 -08:00
John Bodley
0dfa3b99dd [requires.io] Removing obsolete requires.io link (#4564) 2018-03-07 17:39:51 -08:00
John Bodley
826d0631e0 Merge pull request #4567 from john-bodley/john-bodley-payload-error-status-code
[payload] Set status code on error rather than query status
2018-03-07 13:53:06 -08:00
John Bodley
1e8cd0e61e [payload] Set status code on error rather than query status 2018-03-07 13:26:20 -08:00
Grace Guo
369f652bfc [bug] fix shortener url (#4560)
[bug] fix shared explore url
2018-03-07 10:57:33 -08:00
Maxime Beauchemin
b63dc91cd1 Expose hook to inject database connection logic on the fly (#4505)
* Expose hook to inject database connection logic on the fly

This environment configuration setting hook allows administrators to
alter the database connection parameters on the fly based on user
information. This can be use for a variety of purposes:

* rewire a subset of users to use different database user accounts
* pass user related information to the database for logging or QoS
purposes
* ...

* Fixes
2018-03-06 22:35:46 -08:00
Maxime Beauchemin
d817b8ddbb Setting up compression using flask-compress (#4543) 2018-03-06 21:19:29 -08:00
John Bodley
ef4e5ecedf [bugfix] Fixing regression from #4500 (#4549) 2018-03-06 21:19:13 -08:00
John Bodley
01e0a2f071 [landing] Making Dashboards the first/default tab (#4553) 2018-03-06 18:49:17 -08:00
Maxime Beauchemin
2e780e4034 Removing files from MANIFEST.in (#4542) 2018-03-06 09:39:31 -08:00
John Bodley
71d7196137 Merge pull request #4533 from john-bodley/john-bodley-replace-coveralls-with-codecov
[coverage] Replacing coveralls with codecov
2018-03-06 08:00:16 -08:00
John Bodley
150768ee30 [presto] Removing patched presto (#4530) 2018-03-05 23:16:02 -08:00
John Bodley
06c5077691 [dump.rdb] Removing rouge file (#4536) 2018-03-05 23:11:40 -08:00
Luciano Arango
2c5adb6dc3 Add ScopeAI (#4541) 2018-03-05 23:11:01 -08:00
John Bodley
6e0ece76a0 Merge pull request #4534 from john-bodley/john-bodley-setup-url
[setup] Fixing repo URLs
2018-03-05 18:03:04 -08:00
John Bodley
48430a1918 Merge pull request #4500 from john-bodley/john-bodley-fix-pr-4396
[bugfix] Fixing regression introduced in #4396
2018-03-05 16:51:09 -08:00
John Bodley
b01a9bba1f [setup] Fixing URLs 2018-03-05 13:06:08 -08:00
Riku Pelkonen
007ad351cf Pass datasource as form_data param (#4538)
* Pass datasource as form_data param

* add comma after datasource

* change test to match new addSlice
2018-03-05 11:43:59 -08:00
John Bodley
4f7258aaca [coverage] Replacing coveralls with codecov 2018-03-04 13:27:26 -08:00
Ariel Shemtov
413585448e Superset issue #4512: fixing histogram (#4513)
* fixing histogram axes and colors, adding normalized and x-axis label options

* adding y-axis label option
2018-03-02 13:45:46 -08:00
EvelynTurner
41defdceaa Fix how the annotation layer interpretes the timestamp string without timezone info; use it as UTC (#4511) 2018-03-01 21:02:04 -08:00
Grace Guo
2637d3d5e2 [dashboard] (#4515) 2018-03-01 15:48:04 -08:00
Gabe Lyons
79bb54a173 chart style options get their own tab (#4482) 2018-03-01 14:24:09 -08:00
Jeffrey Wang
3a58dc7ecf Make margin width based on container width instead of slice width (#4487)
* Make width based on container width instead of slice width

* fix const var name and add comment

* Actually 30 looks good too
2018-02-28 15:48:15 -08:00
John Bodley
7440d34936 [payload] Fixing regression introducted in ##4396 2018-02-28 14:23:20 -08:00
Gabe Lyons
764a92cd10 [Explore] applying refresh chart overlay when chart is stale (#4486)
* adding refresh chart overlay when chart is out of sync with control panel

* fading the visualization when stale

* addressing comments from team on layout of UI
2018-02-28 14:19:06 -08:00
Maxime Beauchemin
849a2cecee Add https support for Druid (#4480)
* Add https support for Druid

* addressing comment
2018-02-28 10:12:17 -08:00
Maxime Beauchemin
264822b1ee Introduce an onInit method for when a new viz_type is selected (#4491)
* Introduce an onInit method for when a new viz_type is selected

This allows for clearing certain controls where/when needed. For
instance here, when loading deck_scatter, even if there was a time
granularity picked for the previous viz_type, we want to unselect it.

* making it functional
2018-02-27 22:36:52 -08:00
timifasubaa
404e2d552a fixes to csv - hive upload (#4488) 2018-02-27 22:13:06 -08:00
timifasubaa
8626793655 check for access before requesting access (#4469) 2018-02-27 17:43:37 -08:00
Maxime Beauchemin
c2b42c49c6 Change limit form 50k to 10k (#4496) 2018-02-27 16:44:02 -08:00
Maxime Beauchemin
83524f97d7 [WiP] Cleanup & fix URL scheme for the explore view (#4490)
* Improve URLs

* Fix js tests
2018-02-27 15:08:06 -08:00
Grace Guo
bcca1717f2 [dashboard] Fix JS error when position_json data is empty (#4485) 2018-02-27 10:18:32 -08:00
Hugh A. Miles II
11ea83ecf1 New Landing Page v1.0 (#4463)
* Updated welcome landing page

* fixed test and linting

* linting

* addressing comments

* fix test

* fix test

* remove unneeded var

* add magic comments
2018-02-26 17:02:41 -08:00
Gabe Lyons
56f65158a2 [Explore] highlighting run query when chart is stale on explore view (#4459)
* highlighting run query when chart is stale on explore view

* refactoring control changed code
2018-02-26 10:57:20 -08:00
Maxime Beauchemin
2932585c65 [geo] add controls for minRadiusPixels and maxRadiusPixels in deck_scatter (#4467) 2018-02-26 10:56:19 -08:00
John Bodley
d57a37e341 [flake8] Adding flake8-coding (#4477) 2018-02-25 15:06:11 -08:00
Jinyang Zhou
ff685db4d9 add organization (#4478) 2018-02-25 15:00:10 -08:00
Raffaele Spangaro
094eb71f86 [FilterBox] Make filterbox localizable (#4466)
* Make filterbox i18n

* Change double-quote to single-quote in localization function t() to pass
lint test

* Updated .po file with italian translation. New strings generated and translated via babel-extract
2018-02-25 14:58:14 -08:00
John Bodley
e112e4417c [flake8] Adding future-import check (#4476) 2018-02-23 16:42:09 -08:00
John Bodley
8aac63e74c [flake8] Fixing additional flake8 issue w/ the presence of ignore (#4474) 2018-02-23 14:46:26 -08:00
Hugh A. Miles II
cacf53c92e Pass param of limit for recent activity (#4475) 2018-02-23 14:18:06 -08:00
timifasubaa
5830846060 [hotfix] resolve utf-8 encoding issue in db migration (#4461)
* [hotfix] resolve utf-8 encoding issue in db migration

* make python string unicode

* Update e866bd2d4976_smaller_grid.py

* Update e866bd2d4976_smaller_grid.py

* rearrange the debug message

* Update e866bd2d4976_smaller_grid.py
2018-02-21 17:45:28 -08:00
Maxime Beauchemin
0eecec10cd [explore] allow URL shortner even if no slice exist (#4457)
recent regression perhaps from the PR that moved to using POST .
2018-02-21 10:35:38 -08:00
Maxime Beauchemin
a373db24f0 Allowing config flag to turn off javascript controls (#4400)
* Allowing config flag to turn off javascript controls

* lint

* one line, avoiding mutation

* Setting JS fields as readOnly
2018-02-21 08:31:07 -08:00
Beto Dealmeida
c3176579e0 Make instant controls store state in URL (#4449)
* Add to history on instant control change

* Update latestQueryFormData on render triggered

* Add new message type

* Update latestQueryFormData in UPDATE_QUERY_FORM_DATA
2018-02-20 17:08:07 -08:00
Maxime Beauchemin
d4a2f4ef36 Make npm run dev-fast the default (#4454) 2018-02-20 17:07:33 -08:00
Gabe Lyons
b60965b8fa [gitignore] Adding venv to .gitignore (#4456)
* fixing spacing issue on internationalization dropdown

* adding venv to gitignore
2018-02-20 17:07:16 -08:00
Maxime Beauchemin
5c35a2d210 A collection of bug fixes (#4444) 2018-02-20 14:41:35 -08:00
Gabe Lyons
c336fe5707 fixing spacing issue on internationalization dropdown (#4455) 2018-02-20 14:13:46 -08:00
Maxime Beauchemin
177d7c07e6 [bugfix] address issue 4206 (#4452)
closes 4206
2018-02-19 09:56:25 -08:00
Grace Guo
5768a1fe5e for 48 columns layout, adjust default size and layout for newly added slices (#4446) 2018-02-19 00:05:57 -08:00
Ville Brofeldt
d6c197f8ac Remove comments from queries in SQL Lab that break Explore view (#4413)
* Remove comments from queries in SQL Lab that break Explore view

This fixes an issue where comments on the last line of the source query comment out the closing parenthesis of the subquery.

* Add test case for SqlaTable with query with comment

This test ensures that comments in the query are removed when calling SqlaTable.get_from_clause().

* Add missing blank line class definition (PEP8)
2018-02-18 16:30:11 -08:00
m4neda
f46bb533cb fix typo. "グルプ分け可能" => "グループ分け可能" (#4450) 2018-02-17 09:25:17 -08:00
Grace Guo
15aa0c5cdd remove html tag in timeout error message (#4447) 2018-02-16 19:44:29 -08:00
Maxime Beauchemin
88e91e6d8f Improve default placeholder text on SelectControl (#4442) 2018-02-16 15:16:55 -08:00
Ville Brofeldt
dc48673647 Removed double call to ConnectorRegistry.sources (#4448)
Removing the double call didn't cause any adverse effects upon removal. If required, a comment motivating the double call should be added.
2018-02-16 15:16:25 -08:00
timifasubaa
7e082968dd Add link on how to get permission to permission error (#4408)
* add flag to config

* add troubleshooting link if there is a link

* nits
2018-02-15 20:28:03 -08:00
Hugh A. Miles II
9478291bf6 Added Example snippet for setting up Redis cache (#4434)
* Added Example snippet for setting up Redis cache

* Update installation.rst

* Update installation.rst
2018-02-15 20:27:03 -08:00
Beto Dealmeida
4ee0833b27 Play scrubber (#4336)
* Initial working prototype

* Small fixes

* Refactoring dekgl

* Show all data when no time grain is selected

* Refactor layers

* Standardize function name

* Fix exports

* Fix require

* Initial working prototype

* Small fixes

* Show all data when no time grain is selected

* Moving play bar to correct location

* Split component

* Working on CSS

* Remove control

* Positioning the play slider

* Fix refresh of slider state

* Fix lint

* Small fixes

* Smoother animation for scans

* Fix versions

* Play/pause with spacebar.

* Small fixes

* Clean stuff that went to other PRs

* Address issues

* Refactor scatter animation
2018-02-15 17:55:11 -08:00
Maxime Beauchemin
6e1d169d0f Change current thumbnails to smaller ones. (#4430)
* Change current thumbnails to smaller ones.

* More density in the VizTypesControl modal
2018-02-15 17:53:20 -08:00
Jeffrey Wang
7922ccfddc Pass in cache timeout for async queries (#4436)
* Pass in cache timeout for async queries

* Default cache timeout to 0 if default env var is not set

* check for 0 timeout
2018-02-15 17:53:00 -08:00
Jay Lindquist
0c87e23877 Fix separator visualization by propagating header height (#4437) 2018-02-15 17:48:57 -08:00
Jay Lindquist
d6f1024d99 Make chart title backgrounds transparent to prevent buttonface color in IE (#4438) 2018-02-15 17:47:40 -08:00
Maxime Beauchemin
680bfc1b43 [dashboard] more granular grid layout (#4416)
Moving to a grid that is 4 times more granular. 48 columns.

Shipping a db migration script which will upgrade the position metadata
to reflect this change.

Also adapting the examples to the new grid parameters.
2018-02-15 17:47:19 -08:00
Hugh A. Miles II
1e99f9eb95 Added check cache key util (#4432)
* added check cache key util

* change docstring

* add has_access_api decorator
2018-02-15 13:43:58 -08:00
Raffaele Spangaro
e943c25790 Updated Italian Translation (#4418)
* Updated Italian Translation

* Merging changes suggested by @xrmx

* Improved translation and typo fixed with changes suggest by @xrmx
2018-02-14 16:21:19 -08:00
Raffaele Spangaro
21e495c1ef Add .1s option to D3 Format dropdown (#4431) 2018-02-14 16:20:59 -08:00
timifasubaa
fa0aa33767 Disable user access request (#4405)
* add feature flag to config

* wrap check around a feature flag

* add flag to the model view

* remove access request from seurity tests
2018-02-14 14:49:22 -08:00
Riccardo Magliocchetti
22d555b14e Bump dependencies with security issues (#4427)
* assets: bump mathjs to 3.20.2

* assets: bump moment to 2.20.1
2018-02-14 09:44:44 -08:00
Grace Guo
342180b263 [Explore view] Use POST method for charting requests (#3993)
* [Explore view] Use POST method for charting requests

* fix per code review comments

* more code review fixes

* code review fix: remove duplicated calls for getting values from request

* [Explore view] Use POST method for charting requests

* fix per code review comments

* more code review fixes

* code review fix: remove duplicated calls for getting values from request
2018-02-13 17:21:15 -08:00
Maxime Beauchemin
d2d973153f Unset 'series limit' default from 50 to null (#4410)
Setting "Series Limit" by default results in a subquery (or 2 phase)
which can be suboptimal / unecessary where low cardinality dims
are used.
2018-02-13 11:17:19 -08:00
Chun-LingChen
5badec38e4 use full path in case of there are query params (#4411) 2018-02-13 11:17:02 -08:00
Maxime Beauchemin
e0bbb0c77e [geo] introduce "Auto Zoom" control (#4389)
* [geo] introduce "Auto Zoom" control

On geospatial visualization, checking the "Auto Zoom" control makes it
such that the viewport is fitted to the data upon rendering the chart.

For dashboards with region filters, the map should jump to the right
position.

Eventually we should enhance this to fly and ease to the position in an
animated way.

* Added TODO notes
2018-02-13 11:10:15 -08:00
Grace Guo
db24cef03b [SqlLab] Fix a few UI issues (#4401)
1. tab alignment css
2. if tabs are more than 1 row, need to calculate content area height
3. clean up height calculation.
2018-02-13 10:18:09 -08:00
mxmzdlv
4a6adb2f27 Check class name string instead of checking the instance (#4404)
This fixes an issue with the newer Google's DBAPI library, which moved Row from google.cloud.bigquery._helper.Row to google.cloud.bigquery.Row, causing ImportError
2018-02-12 21:16:42 -08:00
Maxime Beauchemin
d85cd5a972 [error handling] 'Time Comparison' query returns no data (#4380) 2018-02-12 11:48:14 -08:00
Xiao Hanyu
5305bdb267 Typo fix: dashbaord -> dashboard. (#4383) 2018-02-10 14:52:17 -08:00
Maxime Beauchemin
ae7a9dc63d Fix markup broken since cache related changes (#4396) 2018-02-09 15:55:45 -08:00
Rodolphe Quiédeville
f9106f80fd Add PeopleDoc in organizations list who use superset (#4178) 2018-02-09 15:11:29 -08:00
David Dworken
4ff17ffc8d Fix 4 security vulnerabilities (#4390)
* Switched yaml.load to yaml.safe_load to prevent code execution via crafted yaml files

Python's yaml.laod can lead to code execution via crafted yaml files such as:

```
code_exec: !!python/object/apply:subprocess.check_output ['ls']
```

* Fixed XSS via bleach

It was possible to get an XSS via the markdown library via simply setting a description containing arbitary HTML tags.
It was also possible to create links that went to the `javascript:` link handler (eg `[example](javascript:alert(0)`)
Using bleach to sanitize it solves both of these.

* Added XFO header by default to prevent clickjacking attacks

Note that with this application clickjacking can be relatively severe via the SQLLab functionality
which allows executing arbitary SQL.

* Added justification for dangerouslySetInnerHTML

* Fixed linting errors

* Fixed linting errors
2018-02-09 14:33:29 -08:00
Maxime Beauchemin
1769804ffd Minor fixes to sunburst (#4349)
* Minor fixes to sunburst

closes https://github.com/apache/incubator-superset/issues/4340

* nit
2018-02-09 14:27:22 -08:00
Jay Lindquist
54d387598d Add permission checks to save_or_overwrite_slice (#4346)
* Add permissions checks for save_or_overwrite_slice

* Change is_owner to check_ownership

* Add translation to chart and dashboard error messages

* Appease the python linter by using single quotes
2018-02-08 16:40:46 -08:00
Grace Guo
5ab4915a1f Remove permission check for frontend logging API (#4388) 2018-02-08 11:50:51 -08:00
Maciej Bryński
387bf766d3 Superset issue #4323 (#4353)
Adding configurable poll interval for Hive Engine
2018-02-07 21:29:31 -08:00
Maxime Beauchemin
0480fa0121 Bump pydruid to 0.4.1 (#4377) 2018-02-07 16:45:44 -08:00
John Bodley
6f1150fef4 [revert] Reverting PR #4062 (#4359) 2018-02-07 15:56:07 -08:00
Maxime Beauchemin
2e172d77cf Fix caching issues (#4316) 2018-02-07 14:49:19 -08:00
Maxime Beauchemin
8fe1f8fb3f Set default row_limit to 50k (#4372) 2018-02-07 14:34:14 -08:00
Maxime Beauchemin
c4eba9e467 [line] improve feature (#4363)
Require Since and Until parameter as they are needed to time shift
2018-02-07 14:33:04 -08:00
Maxime Beauchemin
90d9616f2b Remove dangerouslySetInnerHTML in StackTraceMessage component (#4373)
Druid sometimes returns error message that are contained in "<>", as in
`<urlopen error [Errno 61] Connection refused>`. 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.
2018-02-07 14:32:45 -08:00
Maxime Beauchemin
803738436e Bump python dependencies (#4341)
* Bump python dependencies

* Fix conflict
2018-02-07 14:32:29 -08:00
Beto Dealmeida
f14c1bb593 Add hour grain to Sqlite (#4333) 2018-02-07 14:07:15 -08:00
Maxime Beauchemin
31a0b6e5b0 [druid] fix bug around handling NULLs (#4358)
fillna would miss out on identifying STRING columns for Druid and
replace None in string columns with a numeric `0`. This
mixed type column would confuse
pandas down the line on some operations like `df.pivot_table`.
2018-02-07 08:19:48 -08:00
Xiao Hanyu
27538386bc Add ipdb to dev dependencies. (#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.
2018-02-07 08:19:18 -08:00
Teemu Haapoja
3b35ddf135 convert postgresql date_trunc() to UTC to prevent pandas error (#4319)
* cast postgresql date_trunc() to timestamp without time zone to prevent pandas error

* fix formatting for flake8

* change cast to timezone conversion instead
2018-02-07 08:18:11 -08:00
Xiao Hanyu
d5ab6c8d3d Remove useless empty npm-debug.log (#4367)
The log file comes from
a7a6678d5c

Also modify .gitignore to ignore all future npm-debug.log
2018-02-07 08:12:45 -08:00
Raffaele Spangaro
a4ecff4e23 New options for european time format in in D3_TIME_FORMAT_OPTIONS (#4364)
* Update installation.rst for Ubuntu 16.04 LTS 

Ubuntu 16.04 by default install python2.7 alongside with python 3.5 and set python2.7 as default. If you have created a virtualenv with python3.5 compilation fails due to wrong python-dev library installed. 

If you install ``python3.5-dev`` the build for the wheel package of  ``cryptography`` run fine.

* Add options in D3_TIME_FORMAT_OPTIONS for non-english Time Format.
Added '%d/%m/%Y' and '%d/%m/%Y %H:%M:%S' as valid drop-down option for Axis Format
2018-02-06 16:24:00 -08:00
michellethomas
19a0827d1f Adding dashboard add view (#4344)
* Adding DashboardAddView and setting show_columns on SLiceAddView

* Adding tests for sliceaddview read api

* Dedupe show_columns
2018-02-06 12:38:07 -08:00
timifasubaa
2d8a0cc6c9 fix uri form data' (#4345)
'
2018-02-05 20:49:37 -08:00
Hugh A. Miles II
2789385688 read query params for json in dashboard endpoint (#4337) 2018-02-05 11:48:12 -08:00
Grace Guo
e965f95477 1. fix check filters change logic (#4339)
2. should show chart after loading completed
2018-02-05 10:21:17 -08:00
liutgnu
ad212272d1 Fix the bug of charts/slices cannot be filtered by datasource name. (#4338) 2018-02-04 23:03:44 -08:00
timifasubaa
6d37d97ba5 Refactor import csv (#4298)
* move helpers to utils

* make form use queryselector

* refactor exception throwing and handling

* update db_connection access point

* nits
2018-02-03 20:22:06 -08:00
Jeff Niu
fdd42ef4b6 [New Viz] Nightingale Rose Chart (#3676)
* Nightingale Rose Chart

* Review comments
2018-02-03 20:18:24 -08:00
Maxime Beauchemin
a616bf4082 [cli] permission cleanup on 'superset init' (#4241)
* [cli] permission cleanup on 'superset init'

FAB sometimes creates NULL/None permissions in the database,
presumably a race condition when multiple gunicorn workers start at the
same time, and those create issues raising "AttributeError: 'NoneType'
object has no attribute 'name'"

* Linting
2018-02-03 20:12:45 -08:00
fabianmenges
a9e1e685ba [BugFix]: Creating a PostgresBaseEngineSpec so changes to the Postgre… (#4224)
* [BugFix]: Creating a PostgresBaseEngineSpec so changes to the PostgresEngineSpec don't affect every subclass

* Empty engine for abstract Engine
2018-02-03 20:03:02 -08:00
Maxime Beauchemin
d41418eaa0 Bump pyrdruid to 0.4.0 (#4325) 2018-02-03 19:48:38 -08:00
Maxime Beauchemin
1f8fccc0f9 [explore] fix missing CacheLabel (#4326)
Also adding a basic unit test.
2018-02-02 10:28:38 -08:00
Raffaele Spangaro
75a2b4f610 Update installation.rst for Ubuntu 16.04 LTS (#4321)
Ubuntu 16.04 by default install python2.7 alongside with python 3.5 and set python2.7 as default. If you have created a virtualenv with python3.5 compilation fails due to wrong python-dev library installed. 

If you install ``python3.5-dev`` the build for the wheel package of  ``cryptography`` run fine.
2018-01-31 18:03:16 -08:00
Grace Guo
133f98ad58 [Bug] Resize should trigger chart re-render (#4322) 2018-01-31 18:02:16 -08:00
Grace Guo
1a7ef4758b [Explore] Fix Stop Query Button behavior (#4301) 2018-01-31 09:34:08 -08:00
Beto Dealmeida
c77bab8160 Refactoring deckgl (#4293)
* Refactoring dekgl

* Refactor layers

* Standardize function name

* Fix exports

* Fix require

* Fix lint
2018-01-30 23:03:35 -08:00
Grace Guo
724c3f48a4 add frontend logging utility function (#4226)
add loading log for dash and exploreview
breakdown whole page load action to multiple charts loading events and render events
2018-01-30 10:27:13 -08:00
Hugh A. Miles II
073d56cb33 Added Path, Polygon, and Arcs to deckGL example dashboard (#4242)
* Added Path, Polygon, and Arcs to deckGL example dashboard

* reorder task

* formatting...

* fix flights reference

* cleanup on aisle 9
2018-01-29 11:51:36 -08:00
Maxime Beauchemin
e4a95f9428 Use the query_obj as the basis for the cache key (#4260)
* Use the query_obj as the basis for the cache key

When we recently moved from hashing form_data to define the cache_key
towards using the rendered query instead,
it made is such that non deterministic form
control values like relative times specified in "from" and "until" time
bound resulted in making those miss cache 100% of the time.

Here we move away from using the rendered query and using the query_obj
instead.

* Deprecating using form_data in templates
2018-01-28 09:46:13 -08:00
Riccardo Magliocchetti
1b06140bde Bump sqlalchemy to 1.2.2 (#4299)
* Bump sqlalchemy to 1.2.2

Fix #4196

* Bump sqlalchemy-utils to 0.32.21
2018-01-28 09:32:41 -08:00
Maxime Beauchemin
f8dcbf70c5 Reverts apache/incubator-superset#4244 (#4303) 2018-01-26 18:09:09 -08:00
michellethomas
b9299d61ac Fixing json decode error on druiddatasourcemodelview/api/read (#4291) 2018-01-25 17:12:34 -08:00
Hugh A. Miles II
2384ad4eb5 [geo] Add JS controls to remaining layers (#4272)
* Update viz.py

* added JS controls

* add JS to grid layout

* add JS to hexagon layer

* added JS controls to screengrid

* update to js_data_mutator controls

* remove .map()
2018-01-25 14:07:34 -08:00
Maxime Beauchemin
2b66eadee2 Set point size control's default for deck_scatter viz (#4261) 2018-01-24 16:49:37 -08:00
Maxime Beauchemin
94d9337e0b deck_multi to pass down filters to layers (#4270)
Filters applied to deck_multi will be passed down to layers as.

If the column isn't set as "filterable", the filter is ignored.

Also note that Dashboard configuration in regards to
"filter_immune_slices" and such will be disregarded in this context as
it isn't the dashboard controller passing down the filter and that
context is not easily accessible here.
2018-01-24 16:26:31 -08:00
Maxime Beauchemin
a0621e10a8 Handle 'pd.Timestamp' when jsonifying (#4275) 2018-01-24 16:09:22 -08:00
Maxime Beauchemin
b72d5b03dc Prevent FilterBox extra query (#4276)
closes https://github.com/apache/incubator-superset/issues/4249
2018-01-24 16:09:03 -08:00
Maxime Beauchemin
914480ad3c Fix SUPERSET_WEBSERVER_TIMEOUT in VisualizeModal (#4277)
* Fix SUPERSET_WEBSERVER_TIMEOUT in VisualizeModal

* Fix test

* lint
2018-01-24 16:08:48 -08:00
Maxime Beauchemin
ff2f85f39b [geo] JS function to receive the whole data array instead of individual object (#4262)
Moving from having the user define an interceptor function that operates
on one object at a time.

By passing the entire array, it's possible to do multiple pass where
needed. A common pattern might be to figure out the max value in order
to define a scaler function. That's only possible if dealing with the
whole array.
2018-01-24 13:16:14 -08:00
Maxime Beauchemin
9cf16a4ff2 Fix click on now in DateFilterControl (#4265)
When clicking on `now` or the infinity sign, the popover closes but the
value doesn't show in the label as expected.
2018-01-24 13:15:44 -08:00
Maxime Beauchemin
b90c410c01 [explore] fix empty query message in 'View Query' (#4273) 2018-01-24 13:14:38 -08:00
Xiao Hanyu
77d1e5d046 Always use fluid container for navbar. (#4279)
As in https://github.com/apache/incubator-superset/pull/4147 removes the
final non fluid container navbar, I think there's no need to keep this
line of code. Just use navbar with fluid container, always.
2018-01-24 08:55:57 -08:00
Marcus Levine
4bc5fe5495 [BUGFIX]: Check datatype of results before converting to DataFrame (#4108)
* conditional check on datatype of results before converting to df

fix type checking

fix conditional checks

remove trailing whitespace and fix df_data fallback def

actually remove trailing whitespace

generalized type check to check all columns for dict

refactor dict col check

* move df conversion to helper and add unit test

add missing newlines

another missing newline

fix quotes

more quote fixes
2018-01-23 20:58:06 -08:00
timifasubaa
2c72a7ae4f Use json for imports and exports, not pickle (#4243)
* make superset imports and exports use json, not pickle

* fix tests
2018-01-23 20:55:27 -08:00
Maxime Beauchemin
4b11f45f72 Using a NullPool for external connections by default (#4251)
Currently, even though `get_sqla_engine` calls get memoized, engines are
still short lived since they are attached to an models.Database ORM
object. All engines created through this method have the scope of a web
request.

Knowing that the SQLAlchemy objects are short lived means that
a related connection pool would also be short lived and mostly useless.
I think it's pretty rare that connections get reused within the context
of a view or Celery worker task.

We've noticed on Redshift that Superset was leaving many connections
opened (hundreds). This is probably due to a combination of the current
process not garbage collecting connections properly, and perhaps the
absence of connection timeout on the redshift side of things. This
could also be related to the fact that we experience web requests timeouts
(enforced by gunicorn) and that process-killing may not allow SQLAlchemy
to clean up connections as they occur (which this PR may not help
fixing...)

For all these reasons, it seems like the right thing to do to use
NullPool for external connection (but not for our connection to the metadata
db!).

Opening the PR for conversation. Putting this query into our staging
today to run some tests.
2018-01-23 15:13:50 -08:00
Maxime Beauchemin
04ae004f43 Set 'Range Filter' default to false (#4264)
It got set to true mistakenly.
2018-01-23 11:23:41 -08:00
Andres Botero
29ef8c4af8 Fix heatmap tooltip disappears under the slice's header (#4268) 2018-01-23 10:16:14 -08:00
Maxime Beauchemin
718230cdf2 Bump flower==0.9.2 (#4263) 2018-01-23 10:15:10 -08:00
John Bodley
8175e19f72 [cache] Fixing json.dumps for timestamp (#4240) 2018-01-19 12:10:39 -08:00
Grace Guo
7b76356182 [Sql Lab] Fix query results display at the bottom of screen (#4246) 2018-01-19 10:19:54 -08:00
Grace Guo
1c56319be4 [Sql Lab] Fix Autorefresh component pulling not stopped. (#4244) 2018-01-19 08:57:23 -08:00
Maxime Beauchemin
36caca3244 Fix 'argument to reversed() must be a sequence' (#4237)
When passing empty/null location data out of certain rows in the spatial
control, Superset raises an error when trying to reverse the tuple.
2018-01-18 15:22:22 -08:00
Hugh A. Miles II
5079b2aa95 Added DeckGL.Polygon Layer w/ JS controls (#4227)
* Working polygon layer for deckGL

* add js controls

* add thumbnail

* better description

* refactor to leverage line_column controls

* templates: open code and documentation on a new tab (#4217)

As they are external resources.

* Fix tutorial doesn't match the current interface #4138 (#4215)

* [bugfix] markup and iframe viz raise 'Empty query' (#4225)

closes https://github.com/apache/incubator-superset/issues/4222

Related to: https://github.com/apache/incubator-superset/pull/4016

* [bugfix] time_pivot entry got missing in merge conflict (#4221)

PR here https://github.com/apache/incubator-superset/pull/3518 missed a
line of code while merging conflicts with time_pivot viz

* Improve deck.gl GeoJSON visualization (#4220)

* Improve geoJSON

* Addressing comments

* lint

* refactor to leverage line_column controls

* refactor to use DeckPathViz

* oops
2018-01-18 13:28:46 -08:00
Hugh A. Miles II
cab8e7d22d remove setting spatial in DeckPathViz class (#4235) 2018-01-18 12:03:46 -08:00
michellethomas
85d137b20a Don't cache if there's no cache key (#4229) 2018-01-18 08:28:26 -08:00
Peter Lubell-Doughtie
a942f81dfd add Ona as a user (#4234) 2018-01-18 08:27:56 -08:00
Maxime Beauchemin
01043c9bf4 Improve deck.gl GeoJSON visualization (#4220)
* Improve geoJSON

* Addressing comments

* lint
2018-01-17 14:01:32 -08:00
Maxime Beauchemin
a9610e2886 [bugfix] time_pivot entry got missing in merge conflict (#4221)
PR here https://github.com/apache/incubator-superset/pull/3518 missed a
line of code while merging conflicts with time_pivot viz
2018-01-17 13:54:45 -08:00
Maxime Beauchemin
5897d85f7a [bugfix] markup and iframe viz raise 'Empty query' (#4225)
closes https://github.com/apache/incubator-superset/issues/4222

Related to: https://github.com/apache/incubator-superset/pull/4016
2018-01-17 13:54:10 -08:00
Yongjie Zhao
0367dce38b Fix tutorial doesn't match the current interface #4138 (#4215) 2018-01-16 21:18:00 -08:00
Riccardo Magliocchetti
1ca1395382 templates: open code and documentation on a new tab (#4217)
As they are external resources.
2018-01-16 21:17:27 -08:00
michellethomas
2607e4be4d Adding limit to time_table viz to get druid query to work (#4207) 2018-01-16 10:27:35 -08:00
Maxime Beauchemin
04680e5ff1 [line chart] fix time shift color (#4202) 2018-01-12 15:10:17 -08:00
John Bodley
a7a6678d5c [cache] Using the query as the basis of the cache key (#4016) 2018-01-12 12:05:12 -08:00
Maxime Beauchemin
8069d6221d [druid] fix 2 phases queries that specify 'Sort By' on 'Series limit' (#4203) 2018-01-12 11:29:24 -08:00
Maxime Beauchemin
269f55c29a [bugfix] dealing with DBAPIs that return unserilizable types (#4200)
Funky datatypes in some databases like BLOBs will have the DBAPI return
python types that can't be serialized to JSON out of the box.

Currently, when this happens SQL Lab fails in a bad way with a gigantic
HTML error message.

This allows specifying a pessimistic JSON serializer handler that will
simply show "Unserializable [type]"
2018-01-12 11:11:31 -08:00
Hugh A. Miles II
bca27b436b [Geo] Added DeckGL Arc Layer and Refactor on BaseDeckGL class (#4134)
* Added DeckGL.arc layer

* added color controls

* added stroke_width control

* added process spatial key methods

* change exception to ValueError

* put location into tuple

* reference global spatial keys array

* linting

* refactor on process_spatial_data_obj

* rm whitespace

* refactor arc.get_data

* Revert "refactor arc.get_data"

This reverts commit 8d01b2a22e.

* add spatial controls array

* refactor on spatial keys again :)

* return altered df

* Working refactor with deckGL Arcs

* working arcs refactor :)

* refactored all other deckGL viz types
2018-01-12 11:06:11 -08:00
Benedict Jin
aecaa85905 Hanization (#4126)
* Hanization

* Hanization step two

* 1. Update mo & json file; 2. Remove necessary msgid & msgstr; 3. Fix error python-format; 4. Other improvements

* Hanization step three

* Hanization step four (49%)

* Translate chart options

* Translate Search

* Translate view results Data preview new table name 10 seconds 30 seconds 1 minute 5 minutes

* Hanization & update mo/json files

* Update filter translation

* Hanization step 5th (60%)

* Hanization step 6th (70%)

* Hanization step 7th (80%)

* Hanization step 8th (83%)
2018-01-12 08:11:37 -08:00
bolkedebruin
7e36488f03 Superset was using undefined metrics for specifying limits (#4114)
in case a form did not specify a metric (e.g. mapbox). If it is
not available it now defaults to the first dimension instead.

This fixes issue #3604
2018-01-11 21:45:34 -08:00
Maxime Beauchemin
87c3e831a8 Using user-defined Javascript to customize geospatial visualization (#4173)
* Using JS to customize spatial viz and tooltips

* Add missing deck_multi.png

* Improve GeoJSON layer with JS support and extra controls

* Addressing comments
2018-01-11 15:42:44 -08:00
Maxime Beauchemin
ee63ebc8ec [datasource editor] click checkbox creates metrics instantly (#4183)
* [datasource editor] click checkbox creates metrics instantly

* Fix tests
2018-01-11 15:42:19 -08:00
Maxime Beauchemin
5916291901 [explore] fix json highlighting for Druid queries (#4201) 2018-01-11 15:41:28 -08:00
Maxime Beauchemin
4b0f252170 Sort out dependencies in travis/tox (#4186)
* Make travis a bit more lean

* Bump npm to 5.6.0
2018-01-10 21:46:10 -08:00
Beto Dealmeida
9176a4072b Enable SQL syntax highlighting in View Query (#4184)
* Enable SQL syntax highlighting in View Query

* Enable SQL syntax highlighting in View Query
2018-01-10 20:49:28 -08:00
John Bodley
0cb7c5e4a6 [annotations] Fixing migration for annotation layers (#4187) 2018-01-10 08:50:05 -08:00
Yongjie Zhao
e182f7f962 fix since or until is empty value #4170 (#4176) 2018-01-09 16:54:18 -08:00
fabianmenges
23c98294bd Moving the custom_password_store out of Database class (#4182) 2018-01-09 13:14:20 -08:00
John Bodley
22bdd9e324 [security] Adding all derived FAB UserModelView views to admin only (#4180) 2018-01-09 13:05:37 -08:00
Maxime Beauchemin
b159e51787 Don't use fully qualified column names in metric definitions (#4101)
When generating an auto SUM() metric on a column, Superset currently
will go `SUM(table_name.column_name)`. This is an issue when moving to
point to another table. It's common to work on some temporary table or
work table and eventually need to point Superset to an alternate table.
2018-01-08 22:03:37 -08:00
John Bodley
d57012067b [FAB] configuring updating of permissions (#4172) 2018-01-08 14:39:18 -08:00
timifasubaa
9364fb5b79 Allow alpha role import csv (#4164)
* allow alphas upload csv

* nits
2018-01-08 13:36:30 -08:00
Maxime Beauchemin
c49fb0aa9b Make Welcome page into a simple React app (#4147)
* Make Welcome page into a simple React app

This removes a dependency on datatables, we should be able to get rid
of it as we re-write the Table and PivotTable viz

* tests/lint

* Bump node version to latest
2018-01-07 22:13:06 -08:00
Grace Guo
b9af019567 Fix chart rendering error in time series table (#4156) 2018-01-06 16:49:59 -08:00
Grace Guo
e7f8143c3b [Bug] Closing change datasource modal throws JS error (#4157) 2018-01-05 14:21:52 -08:00
Alexander Tronchin-James
c9e47f0bb3 Check for non-None database before using. (#4162)
Some valid sqlalchemy uri's return a URL object with database=None, which causes the following error:
```
2018-01-05 17:59:47,560:ERROR:root:argument of type 'NoneType' is not iterable
Traceback (most recent call last):
  File "/opt/incubator-superset/superset/sql_lab.py", line 186, in execute_sql
    user_name=user_name,
  File "/opt/incubator-superset/superset/utils.py", line 124, in __call__
    return self.func(*args, **kwargs)
  File "/opt/incubator-superset/superset/models/core.py", line 644, in get_sqla_engine
    url = self.db_engine_spec.adjust_database_uri(url, schema)
  File "/opt/incubator-superset/superset/db_engine_specs.py", line 505, in adjust_database_uri
    if '/' in database:
TypeError: argument of type 'NoneType' is not iterable
```
This patch corrects that problem.
2018-01-05 13:54:17 -08:00
Beto Dealmeida
686023c8dd Druid support via SQLAlchemy (#4163)
* Use druiddb

* Remove auto formatting

* Show prequeries

* Fix subtle bug with lists

* Move arguments to query object

* Fix druid run_query
2018-01-05 13:52:58 -08:00
Benedict Jin
d997a450cf Fix invaild gitter url (#4125) 2018-01-04 14:45:58 -08:00
zhao yongjie
9e053923d4 Adding Apache Kylin datasource for documentation (#4148) 2018-01-03 20:24:15 -08:00
Leonardo Rochael Almeida
ef06a9d497 Create DATA_DIR after importing config (#4143)
Delay creating DATA_DIR until config is fully imported.

This allows superset_config.py to override DATA_DIR before superset
attempts to create it in a potentially unwriteable location.
2018-01-03 09:54:59 -08:00
Maxime Beauchemin
37205099db Fix USA's state geojson for 'Country Map' visualization (#4121)
* Fix USA's state geojson for 'Country Map' visualization

Turns out the ISO codes were missing from the geojson file, this adds it
and uses human-readable indents.

* using proper ISO codes

* Linting

New linting rules started applying, I'm guessing a new version of
pylint?
2018-01-02 20:21:33 -08:00
timifasubaa
e498f2fcb6 fix variable name (#4139) 2018-01-02 14:32:24 -08:00
Jeff Niu
f7c55270db Remedy for dual axis annotation (#4130) 2018-01-02 14:31:16 -08:00
Maxime Beauchemin
0a6208296e [explore] add datasource metadata (#4104) 2018-01-02 08:41:27 -08:00
Hugh A. Miles II
bf4d3a0dff better thumbnail for deck_geojson (#4135) 2017-12-28 13:38:07 -08:00
Hugh A. Miles II
b227612f6e Added guard statement for spatial controls (#4124) 2017-12-26 12:27:27 -08:00
Maxime Beauchemin
45686a1af6 Multi layers DECK.GL visualization (#4096)
* Multi layers DECK.GL viz

* Fix tests

* rebasing

* Fix error handling in chartActions

* Addressing comments
2017-12-26 10:47:29 -08:00
Benedict Jin
82ed4878c4 Fix rst grammar problems (#4116) 2017-12-25 23:39:28 -08:00
James Pesculis
6e1ec8347d Update UserInfo.jsx and set additional properties for react-gravatar (#4118) 2017-12-25 23:29:27 -08:00
Hugh A. Miles II
f905726c24 [geo] Added DeckGL GeoJson layer (#4097)
* added deckgl geojson layer

* linting

* fixed comments

* addressed comments

* added override with controls.color_picker > 0

* set var properly

* set colors if property doesnt exist at all

* refacator on property mapping
2017-12-22 14:40:08 -08:00
Maxime Beauchemin
69195f8d2d Introduce Javascript controls (#4076)
* Introduce Javascript controls

This allows power-users to perform intricate transformations on data and
objects using javascript code.

The operations allowed are "sanboxed" or limited using node's vm
`runInNewContext`
https://nodejs.org/api/vm.html#vm_vm_runinnewcontext_code_sandbox_options

For now I'm only enabling in the line chart visualization, but the plan
would be to go towards offering more power to people who can write some
JS moving forward.

* Not applied
2017-12-20 21:24:35 -08:00
Nicolas Bonnotte
b4909f2d03 [Bugfix] Issues with merge_extra_filters (#4042) (#4091) 2017-12-20 16:22:43 -08:00
Maxime Beauchemin
44e753d94d [sql lab] deeper support for templating (#3996)
* [sql lab] deeper support for templating

* Fixing py tests

* Fix typo
2017-12-19 15:55:58 -08:00
Maxime Beauchemin
e4903e6dc6 [geo] add support for deck.gl's path layer (#4067)
* [geo] add support for deck.gl's path layer

Works with json and polyline data.

* Lint
2017-12-19 12:38:03 -08:00
Maxime Beauchemin
d4e8d57fc4 Using TextAreaControl for WHERE and HAVING clause section (#4090) 2017-12-19 12:11:35 -08:00
kuriancheeramelil
281ae45495 Fix for SQL editor throwing can't deserialize google.cloud.bigquery._helpers.Row with BigQuery (#4071)
* fix for SQL editor throwing cant deserialize google.cloud.bigquery._helpers.Row with BigQuery

* linted code

* disable pylint import error of bigquery row

* fixed spacing issue before inline-comment
2017-12-18 21:22:34 -08:00
fabianmenges
ff4f9b4527 Bugfix: Druid having filters are broken (#4089) 2017-12-18 17:06:12 -08:00
fabianmenges
86f9087ea2 Event annotation should have min width (#4083) 2017-12-18 15:37:05 -08:00
Maxime Beauchemin
7cd9b85831 [bugfix] iframe and markup are broken (#4082)
fixes https://github.com/apache/incubator-superset/issues/4080
2017-12-18 14:42:18 -08:00
fabianmenges
71e1eea9f4 DB migration of annotation_layers on slice objects and slimming down annotation object. (#4072) 2017-12-18 13:11:06 -08:00
Jeff Niu
1e79e9cd2a [Bugfix] Issues with table filtering (#4073)
* Fixing some issues with table filtering

* Added some comments
2017-12-17 15:43:34 -08:00
Jeff Niu
af7cdeba4d [Feature] enhanced memoized on get_sqla_engine and other functions (#3530)
* added watch to memoized

* added unit tests for memoized

* code style changes
2017-12-17 10:35:00 -08:00
fabianmenges
500e6256c0 Full Annotation Framework (#3518)
* Adding full Annotation Framework

* Viz types

* Re organizing native annotations

* liniting

* Bug fix

* Handle no data

* Cleanup

* Refactor slice form_data to data
2017-12-16 16:10:45 -08:00
Nic
e79d05fd77 #4058 Fix Oracle timestamps (Oracle "ORA-00907: missing right parenthesis" error) (#4065) 2017-12-15 21:31:09 -08:00
Maxime Beauchemin
fc85756c20 [geo] turn off renderTrigger on viewport control (#4066)
For context, the viewport gets updated dynamically from the user
actions on the map. This is done on a timer every second or so to keep
the form data updated with the viewport settings.

With renderTrigger=true on that control that generates re-renders which
introduces glitches while zooming/panning. So turning it off as we don't
really expect users to input viewport info directly in the control
anyways.
2017-12-15 14:59:54 -08:00
John Bodley
6081f7161a [health] Adding DB check to /health (#4062) 2017-12-15 14:59:41 -08:00
Maxime Beauchemin
c21513fb8c Adding rowcount label to explore view header (#4059) 2017-12-15 11:47:44 -08:00
Maxime Beauchemin
ec752b1378 [geo] provide more flexible Spatial controls (#4032)
Before this PR the only way to query lat/long is in the shape of 2
columns that contains lat and long.

Now we're adding 2 more options:
* a single column that has lat and long with a delimiter in between
* support for geohashes - geohashes are cool
2017-12-15 11:47:27 -08:00
Maxime Beauchemin
cf1d9ce1e6 Add db_engine_spec for Druid (#4063)
The `druiddb` pypi package provides a dbapi and sqlalchemy dialect for
Druid. This PR hooks adds some superset-specific conf.
2017-12-15 11:47:00 -08:00
Maxime Beauchemin
6188d60fec Bump dev version on trunk (#4048) 2017-12-12 21:29:19 -08:00
Maxime Beauchemin
dfc28f37eb Changelog for 0.21.0 (#4045)
* Changelog for 0.21.0

* more entries
2017-12-12 21:29:01 -08:00
Maxime Beauchemin
23c834f04e Fix the pypi build (#4047) 2017-12-12 18:12:26 -08:00
Hugh A. Miles II
c84211ec44 Change reference for slices to chart (#4049)
* change reference for slices to chart

* change profile page reference

* change reference for Associated Slices

* change back to single quotes

* fix other single quotes

* linting

* last one

* fix test
2017-12-12 18:02:17 -08:00
428 changed files with 230421 additions and 7281 deletions

View File

@@ -1,40 +0,0 @@
engines:
csslint:
enabled: false
duplication:
enabled: false
eslint:
enabled: true
checks:
import/extensions:
enabled: false
import/no-extraneous-dependencies:
enabled: false
config:
config: superset/assets/.eslintrc
pep8:
enabled: true
fixme:
enabled: false
radon:
enabled: true
checks:
Complexity:
enabled: false
ratings:
paths:
- "**.py"
- "superset/assets/**.js"
- "superset/assets/**.jsx"
exclude_paths:
- ".*"
- "**.pyc"
- "**.gz"
- "env/"
- "tests/"
- "superset/assets/images/"
- "superset/assets/vendor/"
- "superset/assets/node_modules/"
- "superset/assets/javascripts/dist/"
- "superset/migrations"
- "docs/"

View File

@@ -1 +0,0 @@
repo_token: 4P9MpvLrZfJKzHdGZsdV3MzO43OZJgYFn

6
.gitignore vendored
View File

@@ -26,14 +26,18 @@ app.db
*.sqllite
.vscode
.python-version
.tox
dump.rdb
# Node.js, webpack artifacts
*.entry.js
*.js.map
node_modules
npm-debug.log
npm-debug.log*
yarn.lock
superset/assets/version_info.json
# IntelliJ
*.iml
venv
@eaDir/

View File

@@ -1,22 +0,0 @@
doc-warnings: yes
test-warnings: no
strictness: medium
max-line-length: 90
uses:
- flask
autodetect: yes
pylint:
disable:
- cyclic-import
- invalid-name
- logging-format-interpolation
options:
docstring-min-length: 10
pep8:
full: true
ignore-paths:
- docs
- superset/migrations/env.py
ignore-patterns:
- ^example/doc_.*\.py$
- (^|/)docs(/|$)

View File

@@ -282,7 +282,7 @@ ignored-modules=numpy,pandas,alembic.op,sqlalchemy,alembic.context,flask_appbuil
# List of class names for which member attributes should not be checked (useful
# for classes with dynamically set attributes). This supports the use of
# qualified names.
ignored-classes=optparse.Values,thread._local,_thread._local
ignored-classes=optparse.Values,thread._local,_thread._local,sqlalchemy.orm.scoping.scoped_session
# List of members which are set dynamically and missed by pylint inference
# system, and so shouldn't trigger E1101 when accessed. Python regular

View File

@@ -1,16 +1,12 @@
language: python
services:
- redis-server
addons:
code_climate:
repo_token: 5f3a06c425eef7be4b43627d7d07a3e46c45bdc07155217825ff7c49cb6a470c
cache:
directories:
- $HOME/.wheelhouse/
env:
global:
- TRAVIS_CACHE=$HOME/.travis_cache/
- TRAVIS_NODE_VERSION="7.10.0"
matrix:
- TOX_ENV=flake8
- TOX_ENV=javascript
@@ -19,8 +15,6 @@ env:
- TOX_ENV=py34-sqlite
- TOX_ENV=py27-mysql
- TOX_ENV=py27-sqlite
before_install:
- npm install -g npm@'>=5.4.1'
before_script:
- mysql -u root -e "DROP DATABASE IF EXISTS superset; CREATE DATABASE superset DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci"
- mysql -u root -e "CREATE USER 'mysqluser'@'localhost' IDENTIFIED BY 'mysqluserpassword';"
@@ -30,7 +24,7 @@ before_script:
- export PATH=${PATH}:/tmp/hive/bin
install:
- pip install --upgrade pip
- pip install tox tox-travis
- pip install --upgrade flake8
- rm -rf ~/.nvm && git clone https://github.com/creationix/nvm.git ~/.nvm && (cd ~/.nvm && git checkout `git describe --abbrev=0 --tags`) && source ~/.nvm/nvm.sh && nvm install $TRAVIS_NODE_VERSION
- pip install codecov tox tox-travis
script: tox -e $TOX_ENV
after_success:
- codecov

View File

@@ -1,5 +1,151 @@
## Change Log
### 0.22.1
Fixes 0.22.0
### 0.22.0
Bad empty release
### 0.21.2 (2017/12/11 21:18 +00:00)
- [#3974](https://github.com/apache/incubator-superset/pull/3974) [Bugfix] `_add_filters_from_pre_query` doesn't handle dim specs (#3974) (@Mogball)
- [#4041](https://github.com/apache/incubator-superset/pull/4041) [API] Deprecate /update_role/ API endpoint (#4041) (@john-bodley)
- [#4030](https://github.com/apache/incubator-superset/pull/4030) resolve python2 str() issue (#4030) (@timifasubaa)
### 0.21.1
Bad-empty release
### 0.21.0 (2017/12/08 09:11 +00:00)
- [#4031](https://github.com/apache/incubator-superset/pull/4031) apply custom css for dashboard initially load (#4031) (@graceguo-supercat)
- [#3891](https://github.com/apache/incubator-superset/pull/3891) [BUGFIX]: Fixing dttm_sql_literal to use python_date_format when specified. (#3891) (@fabianmenges)
- [#3947](https://github.com/apache/incubator-superset/pull/3947) Add fastdom js dependency (#3947) (@mistercrunch)
- [#4015](https://github.com/apache/incubator-superset/pull/4015) Remove unused callbacks when setting state (#4015) (@betodealmeida)
- [#4017](https://github.com/apache/incubator-superset/pull/4017) Fixed finding postaggregations (#4017) (@Mogball)
- [#3941](https://github.com/apache/incubator-superset/pull/3941) New time_pivot visualization (#3941) (@mistercrunch)
- [#3959](https://github.com/apache/incubator-superset/pull/3959) Add type MONEY as numeric type (#3959) (@mistercrunch)
- [#3969](https://github.com/apache/incubator-superset/pull/3969) Add row_limit to heatmap controls (#3969) (@mistercrunch)
- [#4019](https://github.com/apache/incubator-superset/pull/4019) Add support of another DatabaseError format (#4019) (@dmigo)
- [#3975](https://github.com/apache/incubator-superset/pull/3975) asciifying http header for csv download; fixes #3952 (#3975) (@rumbin)
- [#4001](https://github.com/apache/incubator-superset/pull/4001) Add has_access to import_dashboard (#4001) (@timifasubaa)
- [#3999](https://github.com/apache/incubator-superset/pull/3999) [sql lab] fix position of 'save query' Popover (#3999) (@mistercrunch)
- [#4003](https://github.com/apache/incubator-superset/pull/4003) Call props.onChange only when closing filter (#4003) (@betodealmeida)
- [#3978](https://github.com/apache/incubator-superset/pull/3978) Adding YAML Import-Export for Datasources to CLI (#3978) (@fabianmenges)
- [#4009](https://github.com/apache/incubator-superset/pull/4009) Rollback bulk-delete of table columns (#4009) (@alanmcruickshank)
- [#4000](https://github.com/apache/incubator-superset/pull/4000) Add Datasource Name filter under slice list view (#4000) (@graceguo-supercat)
- [#3997](https://github.com/apache/incubator-superset/pull/3997) Alternate PR to #3970 (#3997) (@mistercrunch)
- [#3976](https://github.com/apache/incubator-superset/pull/3976) [doc] added setting X-Forwarded-Proto to https behind reverse proxy with ssl encryption; fixes #3655 (#3976) (@rumbin)
- [#3991](https://github.com/apache/incubator-superset/pull/3991) Create CODE_OF_CONDUCT.md (#3991) (@mistercrunch)
- [#3967](https://github.com/apache/incubator-superset/pull/3967) [Dashboard] fix a filter refresh bug and add Test (#3967) (@graceguo-supercat)
- [#3965](https://github.com/apache/incubator-superset/pull/3965) [docs] making it clear sqlite shouldn't be used in a cluster (#3965) (@mistercrunch)
- [#3957](https://github.com/apache/incubator-superset/pull/3957) [time series table] visual improvements (#3957) (@williaster)
- [#3958](https://github.com/apache/incubator-superset/pull/3958) Improving speed of dashboard import (#3958) (@michellethomas)
- [#3949](https://github.com/apache/incubator-superset/pull/3949) [Bugfix] Druid `run_query` dimensions part 3 + Unit tests (#3949) (@Mogball)
- [#3946](https://github.com/apache/incubator-superset/pull/3946) [country_map] use Albers USA projection (#3946) (@mistercrunch)
- [#3948](https://github.com/apache/incubator-superset/pull/3948) fix 'superset db history' (#3948) (@mistercrunch)
- [#3951](https://github.com/apache/incubator-superset/pull/3951) Allow underscores in slugs (#3951) (@michellethomas)
- [#3955](https://github.com/apache/incubator-superset/pull/3955) config: bring back sqlite default database (#3955) (@xrmx)
- [#3940](https://github.com/apache/incubator-superset/pull/3940) Add an "Edit Mode" to Dashboard view (#3940) (@mistercrunch)
- [#3920](https://github.com/apache/incubator-superset/pull/3920) Fixed branching condition with dimension spec (#3920) (@Mogball)
- [#3643](https://github.com/apache/incubator-superset/pull/3643) Import CSV (#3643) (@timifasubaa)
- [#3945](https://github.com/apache/incubator-superset/pull/3945) Fix call in Chart (#3945) (@mistercrunch)
- [#3933](https://github.com/apache/incubator-superset/pull/3933) minor filter select enhancements (#3933) (@kkalyan)
- [#3929](https://github.com/apache/incubator-superset/pull/3929) Make Table Columns & Metrics Bulk-deletable (#3929) (@alanmcruickshank)
- [#3922](https://github.com/apache/incubator-superset/pull/3922) [travis] Standardizing before_install (#3922) (@john-bodley)
- [#3923](https://github.com/apache/incubator-superset/pull/3923) Switched to span instead of textarea for copytoclipboard (#3923) (@Mogball)
- [#3924](https://github.com/apache/incubator-superset/pull/3924) Moved percent metrics to its own row (#3924) (@Mogball)
- [#3875](https://github.com/apache/incubator-superset/pull/3875) Revert "Filter out unavailable databases (#3875)" (#3918) (@mistercrunch)
- [#3913](https://github.com/apache/incubator-superset/pull/3913) [bugfix] remove quotes from Postgres time grains (#3913) (@mistercrunch)
- [#3915](https://github.com/apache/incubator-superset/pull/3915) Fix left padding in dashboard widgets (#3915) (@mistercrunch)
- [#3916](https://github.com/apache/incubator-superset/pull/3916) [cosmetic] remove border from table viz (#3916) (@mistercrunch)
- [#3912](https://github.com/apache/incubator-superset/pull/3912) When checking if you should renderTriggered make sure key exists in controls (#3912) (@michellethomas)
- [#3906](https://github.com/apache/incubator-superset/pull/3906) fix the schema-fetching problem for impala in sql_lab (#3906) (@xiaoyugit)
- [#3911](https://github.com/apache/incubator-superset/pull/3911) Add UK Metropolitan Districts and Isle of Man (#3911) (@alanmcruickshank)
- [#3904](https://github.com/apache/incubator-superset/pull/3904) Bumping webpack related deps (#3904) (@mistercrunch)
- [#3902](https://github.com/apache/incubator-superset/pull/3902) [bugfix] allow limiting word cloud (#3902) (@mistercrunch)
### 0.21.0rc2 (2017/11/20 17:18 +00:00)
- [#3903](https://github.com/apache/incubator-superset/pull/3903) Fixes default hanlding in Altered slice tag (#3903) (@mistercrunch)
- [#3910](https://github.com/apache/incubator-superset/pull/3910) Workaround pandas bug in datetimes with time zones (#3910) (@bolkedebruin)
- [#3583](https://github.com/apache/incubator-superset/pull/3583) [3541] Augmenting datasources uniqueness constraints (#3583) (@john-bodley)
- [#3895](https://github.com/apache/incubator-superset/pull/3895) [druid] Fixing issue 3894 multi-processing w/ Gunicorn (#3895) (@john-bodley)
- [#3897](https://github.com/apache/incubator-superset/pull/3897) [druid] Catch IOError when fetching Druid datasource time boundary (#3897) (@john-bodley)
- [#3899](https://github.com/apache/incubator-superset/pull/3899) [druid] Renaming refresh_async method (#3899) (@john-bodley)
- [#3884](https://github.com/apache/incubator-superset/pull/3884) Add datasource to the SliceAddView modal (#3884) (#3900) (@alanmcruickshank)
- [#3890](https://github.com/apache/incubator-superset/pull/3890) [dashboard bug]Instant control should take effect instantly (#3890) (@graceguo-supercat)
- [#3879](https://github.com/apache/incubator-superset/pull/3879) Allow users to specify label->color mapping (#3879) (@mistercrunch)
- [#3893](https://github.com/apache/incubator-superset/pull/3893) Only refreshing non instant filters on apply (#3893) (@michellethomas)
### 0.21.0rc1 (2017/11/17 17:33 +00:00)
- [#3896](https://github.com/apache/incubator-superset/pull/3896) [druid] Fix datasource column enumeration (#3896) (@john-bodley)
- [#3852](https://github.com/apache/incubator-superset/pull/3852) fix input height to match with react-select (#3852) (@graceguo-supercat)
- [#3887](https://github.com/apache/incubator-superset/pull/3887) Fixing the build's linting errors (#3887) (@mistercrunch)
- [#3851](https://github.com/apache/incubator-superset/pull/3851) A better looking favicon (#3851) (@mistercrunch)
- [#3876](https://github.com/apache/incubator-superset/pull/3876) Fix slug function (#3876) (@mistercrunch)
- [#3880](https://github.com/apache/incubator-superset/pull/3880) [table] show 'Time' column header instead of '__timestamp' (#3880) (@mistercrunch)
- [#3771](https://github.com/apache/incubator-superset/pull/3771) DECKGL integration - Phase 1 (#3771) (@mistercrunch)
- [#3843](https://github.com/apache/incubator-superset/pull/3843) Further refactoring around dashboards (#3843) (@mistercrunch)
- [#3877](https://github.com/apache/incubator-superset/pull/3877) [dashboard bug] Fix standalone slice (#3877) (@graceguo-supercat)
- [#3872](https://github.com/apache/incubator-superset/pull/3872) Add mailing list and move screenshot at the end of README (#3872) (@xrmx)
- [#3875](https://github.com/apache/incubator-superset/pull/3875) Filter out unavailable databases (#3875) (@dmigo)
### 0.20.6 (2017/11/15 05:26 +00:00)
- [#3865](https://github.com/apache/incubator-superset/pull/3865) [issue] Resolving issue 2530 (#3865) (@john-bodley)
- [#3809](https://github.com/apache/incubator-superset/pull/3809) [cache] Fixing cache key w/ merged extra filters (#3809) (@john-bodley)
- [#3869](https://github.com/apache/incubator-superset/pull/3869) Fixing an issue with stripping filter values (#3869) (@michellethomas)
- [#3862](https://github.com/apache/incubator-superset/pull/3862) [flake8] Updaing CONTRIBUTING.md (#3862) (@john-bodley)
- [#3866](https://github.com/apache/incubator-superset/pull/3866) [Dashboard bug] Fix merged filter param name (#3866) (@graceguo-supercat)
- [#3858](https://github.com/apache/incubator-superset/pull/3858) Fix cachedDttm prop type (#3858) (@graceguo-supercat)
- [#3847](https://github.com/apache/incubator-superset/pull/3847) [flake8] Resolving Q??? errors (#3847) (@john-bodley)
- [#3856](https://github.com/apache/incubator-superset/pull/3856) adding support for getting list of foreign tables for PostgreSQL (#3856) (@mike-schiller)
- [#3834](https://github.com/apache/incubator-superset/pull/3834) [Dashboard bug] Slice doesn't show loading icon when loading (#3834) (@graceguo-supercat)
- [#3857](https://github.com/apache/incubator-superset/pull/3857) [Dashboard bug]Fix userId prop in Explore view Save_Modal (#3857) (@graceguo-supercat)
- [#3850](https://github.com/apache/incubator-superset/pull/3850) [sql lab] minor cosmetic touchups on Run / Save buttons (#3850) (@mistercrunch)
- [#3849](https://github.com/apache/incubator-superset/pull/3849) [sqllab] fix wrong error msg (#3849) (@mistercrunch)
- [#3842](https://github.com/apache/incubator-superset/pull/3842) Add CHANGELOG.md entries for 0.20.0 to 0.20.5 (#3842) (@mistercrunch)
- [#3846](https://github.com/apache/incubator-superset/pull/3846) [flake8] Resolving F5?? errors (#3846) (@john-bodley)
- [#3841](https://github.com/apache/incubator-superset/pull/3841) [Dashboard bug] should reset chartAlert when start new query (#3841) (@graceguo-supercat)
- [#3510](https://github.com/apache/incubator-superset/pull/3510) Update setup.py (#3510) (@joriewong)
- [#3833](https://github.com/apache/incubator-superset/pull/3833) [Dashboard bug] Fix Cache status and dttm information display for each slice (#3833) (@graceguo-supercat)
- [#3837](https://github.com/apache/incubator-superset/pull/3837) [Dashboard bug] should reset chartAlert when start new query (#3837) (@graceguo-supercat)
- [#3836](https://github.com/apache/incubator-superset/pull/3836) run_tests.sh: call coveralls only on CI (#3836) (@xrmx)
- [#3838](https://github.com/apache/incubator-superset/pull/3838) [slice] Removing deprecated argument (#3838) (@john-bodley)
- [#3839](https://github.com/apache/incubator-superset/pull/3839) [viz] Fix payload force logic (#3839) (@john-bodley)
- [#3668](https://github.com/apache/incubator-superset/pull/3668) [Explore] Altered Slice Tag (#3668) (@Mogball)
- [#3813](https://github.com/apache/incubator-superset/pull/3813) [docs] add StatsD setup instructions (#3813) (@mistercrunch)
- [#3814](https://github.com/apache/incubator-superset/pull/3814) [flake8] Resolving E3?? errors (#3814) (@john-bodley)
- [#3831](https://github.com/apache/incubator-superset/pull/3831) Bump celery to 4.1.0 (#3831) (@mistercrunch)
- [#3805](https://github.com/apache/incubator-superset/pull/3805) [flake8] Resolve E1?? errors (#3805) (@john-bodley)
- [#3815](https://github.com/apache/incubator-superset/pull/3815) [docstring] Refining warm_up_cache comment (#3815) (@john-bodley)
- [#3822](https://github.com/apache/incubator-superset/pull/3822) First time fetching chart should not force refresh. (#3822) (@graceguo-supercat)
- [#3740](https://github.com/apache/incubator-superset/pull/3740) Basic German Translation (#3740) (@alanmcruickshank)
- [#3816](https://github.com/apache/incubator-superset/pull/3816) [flake8] Resolving E7?? errors (#3816) (@john-bodley)
- [#3817](https://github.com/apache/incubator-superset/pull/3817) [flake8] Resolving E4?? errors (#3817) (@john-bodley)
- [#3819](https://github.com/apache/incubator-superset/pull/3819) Added /healthcheck endpoint for integrations with envoy (#3819) (@hughhhh)
- [#3818](https://github.com/apache/incubator-superset/pull/3818) Fix typo in installation.rst (#3818) (@pswaminathan)
- [#3825](https://github.com/apache/incubator-superset/pull/3825) Fix misleading SQL Lab timeout error message (#3825) (@mistercrunch)
- [#3823](https://github.com/apache/incubator-superset/pull/3823) fix error message format when long query timeout (#3823) (@graceguo-supercat)
- [#3810](https://github.com/apache/incubator-superset/pull/3810) Make overflow important to allow scrolling on dashboard (#3810) (@michellethomas)
- [#3811](https://github.com/apache/incubator-superset/pull/3811) [flake8] Resolving F4?? errors (#3811) (@john-bodley)
- [#3812](https://github.com/apache/incubator-superset/pull/3812) [flake8] Resolving E2?? errors (#3812) (@john-bodley)
- [#3808](https://github.com/apache/incubator-superset/pull/3808) Making time table viz scrollable (#3808) (@michellethomas)
- [#3581](https://github.com/apache/incubator-superset/pull/3581) Dashboard refactory (#3581) (@graceguo-supercat)
- [#3801](https://github.com/apache/incubator-superset/pull/3801) Stamping version to 0.21.0dev (#3801) (@mistercrunch)
- [#3433](https://github.com/apache/incubator-superset/pull/3433) Allowing Leading and Trailing spaces in connection (#3433) (@ishpreet-singh)
- [#3796](https://github.com/apache/incubator-superset/pull/3796) Fixed single extraction dimension error (#3796) (@Mogball)
- [#3787](https://github.com/apache/incubator-superset/pull/3787) [flake8] Resolving C??? errors (#3787) (@john-bodley)
- [#3716](https://github.com/apache/incubator-superset/pull/3716) Update messages.json (#3716) (@magicansk)
- [#3784](https://github.com/apache/incubator-superset/pull/3784) [flake8] Resolving W??? errors (#3784) (@john-bodley)
- [#3797](https://github.com/apache/incubator-superset/pull/3797) [flake8] Resolve I??? errors (#3797) (@john-bodley)
- [#3789](https://github.com/apache/incubator-superset/pull/3789) Add Lyft and Twitter to list of companies (#3789) (@mistercrunch)
- [#3794](https://github.com/apache/incubator-superset/pull/3794) [time table] use sparkData values in tooltip (#3794) (@williaster)
- [#3793](https://github.com/apache/incubator-superset/pull/3793) Adding back iso and correctly filtering iso from contrib total (#3793) (@michellethomas)
- [#3788](https://github.com/apache/incubator-superset/pull/3788) Removing iso from data (#3788) (@michellethomas)
- [#3778](https://github.com/apache/incubator-superset/pull/3778) [flake8] Resolving F8?? errors (#3778) (@john-bodley)
- [#3785](https://github.com/apache/incubator-superset/pull/3785) Rename files to allow RPM build (#3785) (@SpyderRivera)
- [#3783](https://github.com/apache/incubator-superset/pull/3783) [falke8] Resolving F6?? errors (#3783) (@john-bodley)
- [#3529](https://github.com/apache/incubator-superset/pull/3529) [explore] using verbose_name in 'Time Column' control (#3529) (@mistercrunch)
- [#3654](https://github.com/apache/incubator-superset/pull/3654) [Performance] VirtualizedSelect for SelectControl and FilterBox (#3654) (@Mogball)
- [#3697](https://github.com/apache/incubator-superset/pull/3697) DI-1113. ADDENDUM. Authentication: Enable user impersonation for Superset to HiveServer2 using hive.server2.proxy.user (a.fernandez) (#3697) (@afernandez)
### 0.20.5 (2017/11/06 07:18 +00:00)
- [#3776](https://github.com/apache/incubator-superset/pull/3776) [flake8] Enabling flake8 linting (#3776) (@john-bodley)
- [#3774](https://github.com/apache/incubator-superset/pull/3774) [sql-lab] Fixing Run Query tooltip (#3774) (@john-bodley)

View File

@@ -49,7 +49,7 @@ If you are proposing a feature:
implement.
- Remember that this is a volunteer-driven project, and that
contributions are welcome :)
### Questions
There is a dedicated [tag](https://stackoverflow.com/questions/tagged/apache-superset) on [stackoverflow](https://stackoverflow.com/). Please use it when asking questions.
@@ -98,7 +98,7 @@ to manage the Python packages you're about to install:
virtualenv superset-dev
source superset-dev/bin/activate
Finally, to make changes to the rst files and build the docs using Sphinx,
Finally, to make changes to the rst files and build the docs using Sphinx,
you'll need to install a handful of dependencies from the repo you cloned:
cd incubator-superset
@@ -269,11 +269,11 @@ pip install -r dev-reqs.txt
All python tests can be run with:
./run_tests.sh
Alternatively, you can run a specific test with:
./run_specific_test.sh tests.core_tests:CoreTests.test_function_name
Note that before running specific tests, you have to both setup the local testing environment and run all tests.
We use [Mocha](https://mochajs.org/), [Chai](http://chaijs.com/) and [Enzyme](http://airbnb.io/enzyme/) to test Javascript. Tests can be run with:
@@ -292,30 +292,6 @@ Lint the project with:
# for javascript
npm run lint
## Linting with codeclimate
Codeclimate is a service we use to measure code quality and test coverage. To get codeclimate's report on your branch, ideally before sending your PR, you can setup codeclimate against your Superset fork. After you push to your fork, you should be able to get the report at http://codeclimate.com . Alternatively, if you prefer to work locally, you can install the codeclimate cli tool.
*Install the codeclimate cli tool*
```
curl -L https://github.com/docker/machine/releases/download/v0.7.0/docker-machine-`uname -s`-`uname -m` > /usr/local/bin/docker-machine && chmod +x /usr/local/bin/docker-machine
brew install docker
docker-machine create --driver virtual box default
docker-machine env default
eval "$(docker-machine env default)"
docker pull codeclimate/codeclimate
brew tap codeclimate/formulae
brew install codeclimate
```
*Run the lint command:*
```
docker-machine start
eval "$(docker-machine env default)”
codeclimate analyze
```
More info can be found here: https://docs.codeclimate.com/docs/open-source-free
## API documentation
Generate the documentation with:
@@ -428,7 +404,7 @@ https://github.com/apache/incubator-superset/pull/3013
# copy
cp -r /tmp/tmp_superset_docs/ ~/incubator-superset-site.git/
# commit and push to `asf-site` branch
cd ~/incubator-superset-site.git/
git checkout asf-site

View File

@@ -1,8 +1,11 @@
recursive-include superset/data *
recursive-include superset/migrations *
recursive-include superset/static *
recursive-exclude superset/static/assets/docs *
recursive-exclude superset/static/assets/images/viz_thumbnails_large *
recursive-exclude superset/static/docs *
recursive-exclude superset/static/spec *
recursive-exclude superset/static/images/viz_thumbnails_large *
recursive-exclude superset/static/assets/node_modules *
recursive-include superset/templates *
recursive-include superset/translations *

View File

@@ -3,10 +3,9 @@ Superset
[![Build Status](https://travis-ci.org/apache/incubator-superset.svg?branch=master)](https://travis-ci.org/apache/incubator-superset)
[![PyPI version](https://badge.fury.io/py/superset.svg)](https://badge.fury.io/py/superset)
[![Coverage Status](https://coveralls.io/repos/apache/incubator-superset/badge.svg?branch=master&service=github)](https://coveralls.io/github/apache/incubator-superset?branch=master)
[![Coverage Status](https://codecov.io/github/apache/incubator-superset/coverage.svg?branch=master)](https://codecov.io/github/apache/incubator-superset)
[![PyPI](https://img.shields.io/pypi/pyversions/superset.svg?maxAge=2592000)](https://pypi.python.org/pypi/superset)
[![Requirements Status](https://requires.io/github/apache/incubator-superset/requirements.svg?branch=master)](https://requires.io/github/apache/incubator-superset/requirements/?branch=master)
[![Join the chat at https://gitter.im/apache/incubator-superset](https://badges.gitter.im/apache/incubator-superset.svg)](https://gitter.im/apache/incubator-superset?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
[![Join the chat at https://gitter.im/airbnb/superset](https://badges.gitter.im/apache/incubator-superset.svg)](https://gitter.im/airbnb/superset?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
[![Documentation](https://img.shields.io/badge/docs-apache.org-blue.svg)](https://superset.incubator.apache.org)
[![dependencies Status](https://david-dm.org/apache/incubator-superset/status.svg?path=superset/assets)](https://david-dm.org/apache/incubator-superset?path=superset/assets)
@@ -152,6 +151,7 @@ the world know they are using Superset. Join our growing community!
- [AiHello](https://www.aihello.com)
- [Airbnb](https://github.com/airbnb)
- [Aktia Bank plc](https://www.aktia.com)
- [Amino](https://amino.com)
- [Brilliant.org](https://brilliant.org/)
- [Capital Service S.A.](http://capitalservice.pl)
@@ -165,8 +165,11 @@ the world know they are using Superset. Join our growing community!
- [Konfío](http://konfio.mx)
- [Lyft](https://www.lyft.com/)
- [Maieutical Labs](https://cloudschooling.it)
- [PeopleDoc](https://www.people-doc.com)
- [Ona](https://ona.io)
- [Pronto Tools](http://www.prontotools.io)
- [Qunar](https://www.qunar.com/)
- [ScopeAI](https://www.getscopeai.com)
- [Shopee](https://shopee.sg)
- [Shopkick](https://www.shopkick.com)
- [Tails.com](https://tails.com)
@@ -176,6 +179,7 @@ the world know they are using Superset. Join our growing community!
- [Udemy](https://www.udemy.com/)
- [VIPKID](https://www.vipkid.com.cn/)
- [Yahoo!](https://yahoo.com/)
- [Zaihang](http://www.zaih.com/)
- [Zalando](https://www.zalando.com)

View File

@@ -1,7 +1,7 @@
codeclimate-test-reporter
coveralls
flake8
flask_cors
ipdb
mock
mysqlclient
nose

View File

@@ -46,10 +46,10 @@ https://github.com/airbnb/superset/issues?q=label%3Aexample+is%3Aclosed
Can I upload and visualize csv data?
-------------------------------------
------------------------------------
Yes, using the ``Upload a CSV`` button under the ``Sources``
menu item. This brings up a form that allows you specify required information. After creating the table from CSV, it can then be loadede like any other on the ``Sources -> Tables``page.
menu item. This brings up a form that allows you specify required information. After creating the table from CSV, it can then be loaded like any other on the ``Sources -> Tables``page.
Why are my queries timing out?
@@ -106,7 +106,7 @@ edit the ``JSON Metadata`` field, more specifically the
never be affected by any dashboard level filtering.
..code::
.. code-block:: json
{
"filter_immune_slices": [324, 65, 92],
@@ -141,7 +141,7 @@ to be refreshed - especially if some data is slow moving, or run heavy queries.
slices from the timed refresh process, add the ``timed_refresh_immune_slices`` key to the dashboard
``JSON Metadata`` field:
..code::
.. code-block:: json
{
"filter_immune_slices": [],
@@ -157,7 +157,7 @@ Slice refresh will also be staggered over the specified period. You can turn off
by setting the ``stagger_refresh`` to ``false`` and modify the stagger period by setting
``stagger_time`` to a value in milliseconds in the ``JSON Metadata`` field:
..code::
.. code-block:: json
{
"stagger_refresh": false,
@@ -236,11 +236,11 @@ It is possible on a per-dashboard basis by providing a mapping of
labels to colors in the ``JSON Metadata`` attribute using the
``label_colors`` key.
..code::
.. code-block:: json
{
"label_colors": {
"Girls": "#FF69B4",
"Boys": "#ADD8E6"
}
}
{
"label_colors": {
"Girls": "#FF69B4",
"Boys": "#ADD8E6"
}
}

View File

@@ -2,88 +2,88 @@ Gallery
=======
.. image:: _static/img/viz_thumbnails/line.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/bubble.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/table.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/pie.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/bar.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/world_map.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/sankey.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/word_cloud.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/filter_box.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/pivot_table.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/directed_force.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/compare.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/sunburst.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/area.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/big_number.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/big_number_total.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/bullet.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/dist_bar.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/heatmap.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/markup.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/para.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/iframe.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/box_plot.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/treemap.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/cal_heatmap.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/horizon.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/mapbox.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/separator.png
:scale: 25 %
:scale: 50 %
.. image:: _static/img/viz_thumbnails/histogram.png
:scale: 25 %
:scale: 50 %

View File

@@ -72,7 +72,7 @@ In order to import datasources from a YAML file(s), run: ::
superset import_datasources -p <path or filename>
If you supply a path all files ending with ``*.yaml`` or ``*.yml`` will be parsed.
You can apply additional falgs e.g.: ::
You can apply additional flags e.g.: ::
superset import_datasources -p <path> -r

View File

@@ -25,10 +25,10 @@ intelligence web application
endorsed by the ASF.
Overview
=======================================
========
Features
---------
--------
- A rich set of data visualizations
- An easy-to-use interface for exploring and visualizing data
@@ -61,7 +61,7 @@ Features
Contents
---------
--------
.. toctree::
:maxdepth: 2

View File

@@ -53,6 +53,12 @@ the required dependencies are installed: ::
sudo apt-get install build-essential libssl-dev libffi-dev python-dev python-pip libsasl2-dev libldap2-dev
**Ubuntu 16.04** If you have python3.5 installed alongside with python2.7, as is default on **Ubuntu 16.04 LTS**, run this command also
sudo apt-get install build-essential libssl-dev libffi-dev python3.5-dev python-pip libsasl2-dev libldap2-dev
otherwhise build for ``cryptography`` fails.
For **Fedora** and **RHEL-derivatives**, the following command will ensure
that the required dependencies are installed: ::
@@ -148,7 +154,7 @@ around `gunicorn`, it doesn't expose all the options you may need,
so you'll want to craft your own `gunicorn` command in your production
environment. Here's an **async** setup known to work well: ::
gunicorn \
 gunicorn \
-w 10 \
-k gevent \
--timeout 120 \
@@ -167,6 +173,30 @@ work on Windows so the `superset runserver` command is not expected to work
in that context. Also note that the development web
server (`superset runserver -d`) is not intended for production use.
If not using gunicorn, you may want to disable the use of flask-compress
by setting `ENABLE_FLASK_COMPRESS = False` in your `superset_config.py`
Flask-AppBuilder Permissions
----------------------------
By default every time the Flask-AppBuilder (FAB) app is initialized the
permissions and views are added automatically to the backend and associated with
the Admin role. The issue however is when you are running multiple concurrent
workers this creates a lot of contention and race conditions when defining
permissions and views.
To alleviate this issue, the automatic updating of permissions can be disabled
by setting the :envvar:`SUPERSET_UPDATE_PERMS` environment variable to `0`.
The value `1` enables it, `0` disables it. Note if undefined the functionality
is enabled to maintain backwards compatibility.
In a production environment initialization could take on the following form:
export SUPERSET_UPDATE_PERMS=1
superset init
export SUPERSET_UPDATE_PERMS=0
gunicorn -w 10 ... superset:app
Configuration behind a load balancer
------------------------------------
@@ -181,11 +211,11 @@ If the load balancer is inserting X-Forwarded-For/X-Forwarded-Proto headers, you
should set `ENABLE_PROXY_FIX = True` in the superset config file to extract and use
the headers.
In case that the reverse proxy is used for providing ssl encryption,
In case that the reverse proxy is used for providing ssl encryption,
an explicit definition of the `X-Forwarded-Proto` may be required.
For the Apache webserver this can be set as follows: ::
RequestHeader set X-Forwarded-Proto "https"
 RequestHeader set X-Forwarded-Proto "https"
Configuration
-------------
@@ -282,6 +312,8 @@ Here's a list of some of the recommended packages.
| ClickHouse | ``pip install | ``clickhouse://`` |
| | sqlalchemy-clickhouse`` | |
+---------------+-------------------------------------+-------------------------------------------------+
| Kylin | ``pip install kylinpy`` | ``kylin://`` |
+---------------+-------------------------------------+-------------------------------------------------+
Note that many other database are supported, the main criteria being the
existence of a functional SqlAlchemy dialect and Python driver. Googling
@@ -320,6 +352,16 @@ For setting your timeouts, this is done in the Superset metadata and goes
up the "timeout searchpath", from your slice configuration, to your
data source's configuration, to your database's and ultimately falls back
into your global default defined in ``CACHE_CONFIG``.
.. code-block:: python
CACHE_CONFIG = {
'CACHE_TYPE': 'redis',
'CACHE_DEFAULT_TIMEOUT': 60 * 60 * 24, # 1 day default (in secs)
'CACHE_KEY_PREFIX': 'superset_results',
'CACHE_REDIS_URL': 'redis://localhost:6379/0',
}
Deeper SQLAlchemy integration
@@ -399,7 +441,7 @@ metadata from your Druid cluster(s)
CORS
-----
----
The extra CORS Dependency must be installed:
@@ -549,7 +591,7 @@ at the ``/simple_page`` url. This can allow you to run other things such
as custom data visualization applications alongside Superset, on the
same server.
..code ::
.. code-block:: python
from flask import Blueprint
simple_page = Blueprint('simple_page', __name__,
@@ -570,7 +612,7 @@ are logged as well as key events like query start and end in SQL Lab.
To setup StatsD logging, it's a matter of configuring the logger in your
``superset_config.py``.
..code ::
.. code-block:: python
from superset.stats_logger import StatsdStatsLogger
STATS_LOGGER = StatsdStatsLogger(host='localhost', port=8125, prefix='superset')

View File

@@ -10,7 +10,7 @@ Provided Roles
--------------
Superset ships with a set of roles that are handled by Superset itself.
You can assume that these roles will stay up-to-date as Superset evolves.
Even though it's possible for ``Admin`` usrs to do so, it is not recommended
Even though it's possible for ``Admin`` users to do so, it is not recommended
that you alter these roles in any way by removing
or adding permissions to them as these roles will be re-synchronized to
their original values as you run your next ``superset init`` command.

View File

@@ -48,17 +48,25 @@ Available macros
We expose certain modules from Python's standard library in
Superset's Jinja context:
- ``time``: ``time``
- ``datetime``: ``datetime.datetime``
- ``uuid``: ``uuid``
- ``random``: ``random``
- ``relativedelta``: ``dateutil.relativedelta.relativedelta``
- more to come!
`Jinja's builtin filters <http://jinja.pocoo.org/docs/dev/templates/>`_ can be also be applied where needed.
.. autoclass:: superset.jinja_context.PrestoTemplateProcessor
:members:
.. autofunction:: superset.jinja_context.url_param
Extending macros
''''''''''''''''
As mentioned in the `Installation & Configuration <https://superset.incubator.apache.org/installation.html#installation-configuration>`_ documentation,
it's possible for administrators to expose more more macros in their
environment using the configuration variable ``JINJA_CONTEXT_ADDONS``.
All objects referenced in this dictionary will become available for users
to integrate in their queries in **SQL Lab**.

View File

@@ -23,7 +23,7 @@ Under the **Sources** menu, select the *Databases* option:
.. image:: _static/img/tutorial/tutorial_01_sources_database.png
:scale: 70%
On the resulting page, click on the green plus sign, near the top left:
On the resulting page, click on the green plus sign, near the top right:
.. image:: _static/img/tutorial/tutorial_02_add_database.png
:scale: 70%

File diff suppressed because it is too large Load Diff

BIN
dump.rdb

Binary file not shown.

View File

@@ -1,6 +1,7 @@
#!/usr/bin/env bash
echo $DB
rm -f .coverage
export PYTHONPATH=./
export SUPERSET_CONFIG=tests.superset_test_config
set -e
superset/bin/superset version -v

View File

@@ -4,11 +4,9 @@ rm ~/.superset/unittests.db
rm ~/.superset/celerydb.sqlite
rm ~/.superset/celery_results.sqlite
rm -f .coverage
export PYTHONPATH=./
export SUPERSET_CONFIG=tests.superset_test_config
set -e
superset/bin/superset db upgrade
superset/bin/superset version -v
python setup.py nosetests
if [ "$CI" = "true" ] ; then
coveralls
fi

View File

@@ -1,3 +1,9 @@
# -*- coding: utf-8 -*-
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
from collections import defaultdict
from superset import sm

View File

@@ -1,3 +1,9 @@
# -*- coding: utf-8 -*-
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
import json
import os
import subprocess
@@ -5,7 +11,7 @@ import subprocess
from setuptools import find_packages, setup
BASE_DIR = os.path.abspath(os.path.dirname(__file__))
PACKAGE_DIR = os.path.join(BASE_DIR, 'superset', 'assets')
PACKAGE_DIR = os.path.join(BASE_DIR, 'superset', 'static', 'assets')
PACKAGE_FILE = os.path.join(PACKAGE_DIR, 'package.json')
with open(PACKAGE_FILE) as package_file:
version_string = json.load(package_file)['version']
@@ -49,41 +55,46 @@ setup(
'colorama==0.3.9',
'cryptography==1.9',
'flask==0.12.2',
'flask-appbuilder==1.9.4',
'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-compress==1.4.0',
'flask-sqlalchemy==2.1',
'flask-testing==0.6.2',
'flask-testing==0.7.1',
'flask-wtf==0.14.2',
'flower==0.9.1',
'flower==0.9.2',
'future>=0.16.0, <0.17',
'geopy==1.11.0',
'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',
'pydruid==0.3.1',
'polyline==1.3.2',
'pydruid==0.4.1',
'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',
'six==1.10.0',
'sqlalchemy==1.1.9',
'sqlalchemy-utils==0.32.16',
'sqlparse==0.2.3',
'requests==2.18.4',
'simplejson==3.13.2',
'six==1.11.0',
'sqlalchemy==1.2.2',
'sqlalchemy-utils==0.32.21',
'sqlparse==0.2.4',
'thrift>=0.9.3',
'thrift-sasl>=0.2.1',
'unidecode>=0.04.21',
'unicodecsv==0.14.1',
'bleach==2.1.2',
],
extras_require={
'cors': ['Flask-Cors>=2.0.0'],
},
tests_require=[
'codeclimate-test-reporter',
'coverage',
'mock',
'nose',
@@ -91,9 +102,10 @@ setup(
],
author='Maxime Beauchemin',
author_email='maximebeauchemin@gmail.com',
url='https://github.com/airbnb/superset',
url='https://github.com/apache/incubator-superset',
download_url=(
'https://github.com/airbnb/superset/tarball/' + version_string),
'https://github.com/apache/incubator-superset/tarball/' + version_string,
),
classifiers=[
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.4',

View File

@@ -1,3 +1,4 @@
# -*- coding: utf-8 -*-
"""Package's main module!"""
from __future__ import absolute_import
from __future__ import division
@@ -12,6 +13,7 @@ import os
from flask import Flask, redirect
from flask_appbuilder import AppBuilder, IndexView, SQLA
from flask_appbuilder.baseviews import expose
from flask_compress import Compress
from flask_migrate import Migrate
from flask_wtf.csrf import CSRFProtect
from werkzeug.contrib.fixers import ProxyFix
@@ -22,6 +24,9 @@ from superset import utils, config # noqa
APP_DIR = os.path.dirname(__file__)
CONFIG_MODULE = os.environ.get('SUPERSET_CONFIG', 'superset.config')
if not os.path.exists(config.DATA_DIR):
os.makedirs(config.DATA_DIR)
with open(APP_DIR + '/static/assets/backendSync.json', 'r') as f:
frontend_config = json.load(f)
@@ -42,7 +47,7 @@ def parse_manifest_json():
with open(MANIFEST_FILE, 'r') as f:
manifest = json.load(f)
except Exception:
print('no manifest file found at ' + MANIFEST_FILE)
pass
def get_manifest_file(filename):
@@ -149,7 +154,9 @@ appbuilder = AppBuilder(
db.session,
base_template='superset/base.html',
indexview=MyIndexView,
security_manager_class=app.config.get('CUSTOM_SECURITY_MANAGER'))
security_manager_class=app.config.get('CUSTOM_SECURITY_MANAGER'),
update_perms=utils.get_update_perms_flag(),
)
sm = appbuilder.sm
@@ -160,6 +167,10 @@ module_datasource_map = app.config.get('DEFAULT_MODULE_DS_MAP')
module_datasource_map.update(app.config.get('ADDITIONAL_MODULE_DS_MAP'))
ConnectorRegistry.register_sources(module_datasource_map)
# Flask-Compress
if conf.get('ENABLE_FLASK_COMPRESS'):
Compress(app)
# Hook that provides administrators a handle on the Flask APP
# after initialization
flask_app_mutator = app.config.get('FLASK_APP_MUTATOR')

File diff suppressed because it is too large Load Diff

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 103 KiB

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 49 KiB

After

Width:  |  Height:  |  Size: 8.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 50 KiB

After

Width:  |  Height:  |  Size: 9.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

After

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 55 KiB

After

Width:  |  Height:  |  Size: 9.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 132 KiB

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.6 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 31 KiB

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 398 KiB

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 253 KiB

After

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 296 KiB

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 41 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 MiB

After

Width:  |  Height:  |  Size: 140 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 MiB

After

Width:  |  Height:  |  Size: 83 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 104 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 74 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 777 KiB

After

Width:  |  Height:  |  Size: 117 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 578 KiB

After

Width:  |  Height:  |  Size: 75 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 242 KiB

After

Width:  |  Height:  |  Size: 42 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 51 KiB

After

Width:  |  Height:  |  Size: 8.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 162 KiB

After

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 106 KiB

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 48 KiB

After

Width:  |  Height:  |  Size: 8.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 425 KiB

After

Width:  |  Height:  |  Size: 39 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 63 KiB

After

Width:  |  Height:  |  Size: 9.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 161 KiB

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 738 KiB

After

Width:  |  Height:  |  Size: 50 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 314 KiB

After

Width:  |  Height:  |  Size: 42 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 220 KiB

After

Width:  |  Height:  |  Size: 84 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 222 KiB

After

Width:  |  Height:  |  Size: 23 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 106 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 230 KiB

After

Width:  |  Height:  |  Size: 23 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 460 KiB

After

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 194 KiB

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

After

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 270 KiB

After

Width:  |  Height:  |  Size: 53 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 200 KiB

After

Width:  |  Height:  |  Size: 43 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 99 KiB

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 170 KiB

After

Width:  |  Height:  |  Size: 25 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 107 KiB

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 82 KiB

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 64 KiB

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 94 KiB

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 115 KiB

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 133 KiB

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 103 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 49 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 50 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 55 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 132 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 31 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 398 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 253 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 296 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 225 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 177 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 968 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 511 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 433 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 777 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 578 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 242 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 162 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 106 KiB

Some files were not shown because too many files have changed in this diff Show More