Commit Graph
60 Commits
Author SHA1 Message Date
Ville BrofeldtandMaxime Beauchemin 4568b2a532 Add cache_key_wrapper to Jinja template processor (#7816) 2019-07-20 09:12:35 -07:00
Maxime BeaucheminandGitHub 87f50ba0d8 Make SHOW_STACKTRACE config apply across the board (#7845) 2019-07-12 08:58:44 -07:00
John BodleyandGitHub 5c58fd1802 [format] Using Black (#7769) 2019-06-25 13:34:48 -07:00
CongleiandKrist Wongsuphasawat fda1002654 fix: cache issue for api/v1/query (#7507) 2019-05-14 14:21:05 -07:00
John BodleyandMaxime Beauchemin 80d6f5a090 [mypy] Adding mypy linting (#7053) 2019-03-24 20:35:48 -07:00
John BodleyandGitHub 61add606ca [missing values] Removing replacing missing values (#4905) 2019-03-20 17:14:15 -07:00
CongleiandChristine Chambers d5b9795f87 Enhancement of query context and object. (#6962)
* added more functionalities for query context and object.

* fixed cache logic

* added default value for groupby

* updated comments and removed print
2019-03-04 18:06:59 -08:00
Maxime BeaucheminandGitHub 1dd4d7a587 Apply ASF licenses throughout the code base (#5800)
* Add license headers

* reabased

* lint

* Removing licenses from vendors folder
2019-01-15 15:53:27 -08:00
Christine ChambersandMaxime Beauchemin 81349df625 Parse datasource_id as integer on the server side (#6359)
- Datasource ids are being serialized into strings on the client side and python's default json.load doesn't deserialize strings representing integers as integers. Adding an integer parsing step when initializing QueryContext.
2018-11-10 15:45:03 -08:00
Christine ChambersandMaxime Beauchemin 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