Commit Graph

3620 Commits

Author SHA1 Message Date
timifasubaa 77845ab081
add logging to csv upload (#6297) 2018-11-07 18:40:07 -08:00
Christine Chambers 8c0551ed46 [SIP-5] Open a new /api/v1/query endpoint that takes query_obj (#6220)
* [SIP-5] Open a new /api/v1/query endpoint that takes query_obj

- Introduce a new handle_superset_exception decorator to avoid repeating the logic for catching SupersetExceptions
- Create a query_obj_backfill method that takes form_data and constructs a query_obj that will be constructed in the client in the future. Use the backfill in explore_json.
- Create a new /api/v1/query endpoint that takes query_obj only and returns the payload data. Note the query_obj is constructed in the client. The endpoint currently only handles query_obj for table view viz (we'll be adding support to new viz types as we go).
- Unit test to verify the new endpoint for table view

* fix tests and lint errors

* - Move the new query endpoint into its own api.py view.
- Create QueryObject and QueryContext class to encapsulate query_object to be built from the client and additional info (e.g. datasource) needed to get the data payload for a given query
- Remove the query_obj_backfill as we'll start building the first query_object on the client so it no longer makes sense to have a short-lived backfill for the matter of days.

* Fixing lint and test errors

* Fixing additional lint error from the previous rebase.

* fixing additional lint error

* addressing additional pr comments

* Make /query accept a list of queries in the query_context object.

* fixing a lint error

* - Move time_shift based calculation and since, until check into util
- Add typing info for get_since_until
- Add new unit tests to verify time_shift calculation and the since until check
2018-11-07 17:23:52 -08:00
Maxime Beauchemin 4ce475f287 Wrap <LoadableRenderer /> with <ErrorBoundary /> (#6294)
* Wrap <LoadableRenderer /> with <ErrorBoundary />

It appears that since the introduction of <SuperChart />, errors in the
visualization javascript (which are somewhat common and expected,
especially as we'll support plugins) were not handled and the whole
page would throw and go missing.

Here I'm introducing a new <ErrorBoundary /> component that elegantly
wraps other
components and handles errors. It's inspired by:
https://reactjs.org/docs/error-boundaries.html

The default behavior of the component is to simply surface the error
as an <Alert bsStyle="danger" /> and exposes the React stacktrace
when clicking on the error.

It's also possible to use component and pass an onError handler and not
show the default message.

This also fixes some minor bugs in TimeTable.

* Addressing comments
2018-11-07 17:11:52 -08:00
Beto Dealmeida a57603adb4
Geoviz state management fix (#6260)
* Fix deckgl getPoints

* Fix CSS

* Fix zoom

* Fix CategoricalDeckGLContainer

* Fix cypress
2018-11-07 16:51:22 -08:00
Jeffrey Wang 0584e3629f Add separate limit setting for SqlLab (#4941)
* Add separate limit setting for SqlLab

Use separate param for wrap sql

Get query limit from config

unit tests for limit control rendering in sql editor

py unit test

pg tests

Add max rows limit

Remove concept of infinity, always require defined limits

consistency

Assert on validation errors instead of tooltip

fix unit tests

attempt persist state

pr comments and linting

* load configs in via common param

* default to 1k
2018-11-07 15:57:44 -08:00
Maxime Beauchemin aed774e18b
[bugfix] handle Loading spinner properly (#6292)
Addressing post-merge comments in
https://github.com/apache/incubator-superset/pull/6283
2018-11-07 13:04:17 -08:00
Grace Guo 69e8df404d
sql lab localStorage config (#6257) 2018-11-06 23:12:32 -08:00
Maxime Beauchemin 1a4199af7a [bugfix] deckgl scatter CategoricalDeckGLContainer (#6288) 2018-11-06 17:13:55 -08:00
michellethomas cd05d44340
Avoid clearing metric when saving from datasource editor (#6277) 2018-11-06 13:23:55 -08:00
Maxime Beauchemin a1d867cf2f
[dashboard] fix spinners disapear too early (#6283)
Recently I noticed that loading spinners on dashboards would disappear
too early.
2018-11-06 08:51:36 -08:00
Maxime Beauchemin c653ab1e9b
Fix Infinity css warning (#6280) 2018-11-05 22:39:42 -08:00
Krist Wongsuphasawat 124c55c117 rename @superset-ui/core to @superset-ui/connection (#6274) 2018-11-05 18:28:38 -08:00
michellethomas c7f8abc6c5 Adding backwards compatable check to add ago to since if it doesn't exist (#6269) 2018-11-05 16:30:04 -08:00
Chris Williams 7fe8e8aff2
[superset-client] getClientErrorObject for everyone (#6276) 2018-11-05 14:26:22 -08:00
Krist Wongsuphasawat 7373be7163 Add chart names translation (#6273)
* add translation for chart names

* add translation for all chart names

* add missing translation
2018-11-05 12:47:32 -08:00
Jeffrey Wang a1e408a299 Fix typo in druid granularity (#6229) 2018-11-05 11:47:18 -08:00
Maxime Beauchemin 08cdb09714
[explore] raise attention to row_limit being reached (#6252)
* [explore] raise attention to row_limit being reached

* fix test
2018-11-05 08:31:44 -08:00
达斯特兰斯 fb13218472 Dockerfile change because error: E: The method driver /usr/lib/apt/methods/https… (#6258)
* change because error: E: The method driver /usr/lib/apt/methods/https could not be found.
 要提交的变更:
	修改:     contrib/docker/Dockerfile

* 	修改:     contrib/docker/Dockerfile
2018-11-02 18:10:45 -07:00
Joe Bordes c041b6673e i18n(es) (#6270) 2018-11-02 18:00:49 -07:00
Joe Bordes 8dbc20b60a I18n es002 (#6208)
* i18n(es) gtranslator formatting

* i18n(es)

* i18n(es) changes suggested by gettext lint tools
2018-11-02 08:23:34 -07:00
mlboy 3115eec892 Externally Visible Server (#6264)
* Externally Visible Server

Usually, app in docker need to be tested in host

* Update docker-entrypoint.sh
2018-11-02 08:21:57 -07:00
Krist Wongsuphasawat da24b0e0d7 Remove label and showOnExplore. Specific import validators (#6261) 2018-11-01 14:08:15 -07:00
Grace Guo 7d8e3219fc
[Fix] merge since,until request parameter with time_range (#6251) 2018-11-01 12:40:56 -07:00
Krist Wongsuphasawat 02f0616025 Make VizTypeControl use metadata from plugin (#6235)
* Render vis type item using information from registry

* adjust style

* fix unit test

* Remove large thumbnails

* Update addSlice
2018-11-01 11:39:24 -07:00
Beto Dealmeida d1cbb0d000
Update CONTRIBUTING.md (#6259) 2018-11-01 11:19:35 -07:00
michellethomas 2fd18eede7
Setting line chart row_limit to 50000 (#6244)
Setting default row_limit to 50K for line chart
2018-11-01 11:01:13 -07:00
michellethomas d34217ef97
Dashboard filter box default (#6236)
* Setting default FilterBox date filter to No Filter

* Adding test for FilterBox
2018-11-01 09:43:04 -07:00
Junda Yang 59109f62b4 revert the change in config.py (#6255) 2018-10-31 17:56:59 -07:00
Maxime Beauchemin e46ab4db52
Bump Flask, bleach and sync pip-compile (#6239)
* sync pip-compile

* Support Flask >= 1.0.0

* pylint

* Trying something else to fix pylint
2018-10-31 16:58:50 -07:00
Maxime Beauchemin 7b3095d6ff
Fix examples charts/dashboards and refactor (#5881)
* Fix examples charts/dashboards and refactor

* pylinting

* Fix pylint

* Lint the refactor

* Rebased
2018-10-31 15:29:04 -07:00
Rakshit Kumar 9710369d52 Fixed grammatical errors. (#6246)
* Fixed grammatical errors.

* Update druid.rst
2018-10-31 13:32:25 -07:00
Rakshit Kumar bfec5916ed Fixed grammatical errors. (#6245) 2018-10-31 13:31:48 -07:00
Rakshit Kumar 6d0069230c Fixed grammatical errors (#6247) 2018-10-31 13:31:35 -07:00
Rakshit Kumar bc8c8a2168 Fixed typos and grammatical errors (#6248) 2018-10-31 13:31:11 -07:00
Rakshit Kumar db93dca947 fixed grammatical errors and typos (#6249) 2018-10-31 13:30:15 -07:00
Rakshit Kumar 0a701d6115 Corrected name of an area and fixed major grammatical errors (#6250) 2018-10-31 13:29:36 -07:00
Junda Yang c552c125d7 Move metadata cache one layer up (#6153)
* Update wording

* nit update for api endpoint url

* move metadata cache one layer up

* refactor cache

* fix flake8 and DatabaseTablesAsync

* nit

* remove logging for cache

* only fetch for all tables that allows cross schema fetch

* default allow_multi_schema_metadata_fetch to False

* address comments

* remove unused defaultdict

* flake 8
2018-10-31 13:23:26 -07:00
Maxime Beauchemin af38d254f0
[bugfix] cannot add options to FilterBox (#6231)
* [bugfix] cannot add options to FilterBox

* addressing comments
2018-10-30 21:59:57 -07:00
Maxime Beauchemin 2ad8e2ee2b
[sql lab] improve placeholder strings for query search form (#6228) 2018-10-30 21:29:43 -07:00
mlboy 2d4a1ab68a fix misstake (#6237) 2018-10-30 21:28:50 -07:00
John Bodley 1190ebb1a8
[datasource] Ensure SQL Lab link opens in a new tab (#6195) 2018-10-30 17:06:27 -07:00
Krist Wongsuphasawat 1473e2cced Integrate translation module @superset-ui/translation (#6222)
* add translation modules

* Update package.json

* Update instructions in CONTRIBUTING

* Remove old files

* Add new entry point "translation"

* Change imports

* move setupTranslation code

* remove translation from entry

* Update python template

* Refactor utils into smaller, independent files

* Define preamble

* working state

* combine toggleCheckbox with setupApp

* move code block out of document.ready

* move setupClient to preamble

* fix unit tests

* update package version

* delete deletion code
2018-10-30 14:51:44 -07:00
michellethomas 1c4b3e999b
Fix time range filter dropdown (#6223)
* Fix date filter control dropdown default state

* Keep track of selected tab
2018-10-30 14:22:40 -07:00
Grace Guo 1fbdd24820
[fix] typo until (#6233) 2018-10-30 14:22:03 -07:00
达斯特兰斯 e1a3a680f4 fix bug : docker build error with no permission with this floder (#6226)
要提交的变更:
	修改:     contrib/docker/Dockerfile
2018-10-30 10:29:38 -07:00
Maxime Beauchemin 0f6b39a6f7
A few setup.py improvements, removing future lib (#6219) 2018-10-29 21:22:25 -07:00
Grace Guo 7d6a4291e1
[fix][Annotation] Fix override since/until for annotation (#6221) 2018-10-29 15:43:01 -07:00
Sumedh Sakdeo 71d6ff40d0 partition and clustering bigquery keys (#6212)
* partition and clustering bigquery keys

* flake8
2018-10-29 11:23:21 -07:00
Maxime Beauchemin acb44165b4 [deck] allow an array of dynamic of aggregations (#6198)
* [deck] allow an array of dynamic of aggregations

* Adding quantiles

* lint & tests
2018-10-29 11:08:22 -07:00
Maxime Beauchemin 7db11d95b0 [setup.py] allow for range on boto library (#6071) 2018-10-29 11:05:35 -07:00