Commit Graph

1283 Commits

Author SHA1 Message Date
Ville Brofeldt b2ffa268cd
fix(sqla): make text clause escaping optional (#17641) 2021-12-03 12:35:26 +02:00
Elizabeth Thompson 13e19291f2
fix: allow for multiple columns in pivot table report (#17636)
* allow for multiple columns in pivot table report

* fix null data issue

* Update tests/unit_tests/charts/test_post_processing.py
2021-12-02 16:42:37 -08:00
AAfghahi b13d953b34
chore: Added unit test to query context change (#17624)
* a lot of console logs

* added unit test
2021-12-02 08:46:25 -08:00
Ville Brofeldt 0544bee74e
fix(api): incorrect api schema definitions (#17620) 2021-12-01 21:47:22 +02:00
Michael S. Molina 78c5d9ac27
fix: Dashboard API flaky test (#17611) 2021-12-01 10:36:13 -03:00
Michael S. Molina 2f2e8fe412
feat: Adds a key-value endpoint to store the state of dashboard filters (#17536)
* feat: Adds a key-value endpoint to store the state of dashboard filters

* Fixes pylint issues

* Adds openapi schemas

* Adds more tests, move logic to commands and use singular form for the endpoint name

* Fixes model description

* Removes database model

* Adds open api specs

* Simplifies the commands

* Adds more tests

* Validates the value content and submits the correct http status code

* Fixes import order

* Skips flakky test

* Fixes tests

* Updates UPDATING.md
2021-12-01 09:06:49 -03:00
AAfghahi d7e3a601b6
fix: Ch31968query context (#17600)
* a lot of console logs

* import and export of query context
2021-11-30 16:51:00 -08:00
Karthikeyan Singaravelan 11cf15f8dc
chore: Fix deprecated unittest aliases for Python 3.11 compatibility. (#17562)
* chore: Fix deprecated unittest aliases for Python 3.11 compatibility.

* chore: Cache pip dependencies.

* chore: Cache more pip dependencies.
2021-11-26 18:21:01 +02:00
Đặng Minh Dũng ebb34196f2
feat: trino support server-cert (#16346)
Signed-off-by: Đặng Minh Dũng <dungdm93@live.com>
2021-11-26 13:28:15 +02:00
Hugh A. Miles II 2e29f36e78
fix: RBAC for export for dashboard viewers (#17527)
* set out export

* update test

* use default dataset

* update test

* these test work

* fix test

* update

* fix

* fix test

* make the test better
2021-11-25 20:10:41 -08:00
aniaan 5a1c68177e
fix(elasticsearch): time_zone setting does not work for cast datetime expressions (#17048)
* fix(elasticsearch): cast does not take effect for time zone settings

* test(elasticsearch): add test

* fix(test): fix typo

* docs(elasticsearch): add annotation

* docs(elasticsearch): add time_zone desc

* docs(elasticsearch): fix typo

* refactor(db_engine): change convert_dttm signature

* fix(test): fix test

* fix(es): add try catch

* fix(test): fix caplog

* fix(test): fix typo
2021-11-25 11:58:44 +02:00
Geido 83e49fc9ee
feat: Certify Charts and Dashboards (#17335)
* Certify charts

* Format

* Certify dashboards

* Format

* Refactor card certification

* Clear details when certified by empty

* Show certification in detail page

* Add RTL tests

* Test charts api

* Enhance integration tests

* Lint

* Fix dashboards count

* Format

* Handle empty value

* Handle empty slice

* Downgrade migration

* Indent

* Use alter

* Fix revision

* Fix revision
2021-11-24 13:42:52 +02:00
Michael S. Molina 76024313c6
fix: Dashboard access when DASHBOARD_RBAC is disabled (#17511)
* fix: Dashboard access when RBAC is disabled

* Sends 403 when forbidden

* Fixes issort

* Changes assertion

* Allow access to unpublished dashboards that don't have roles

* Fixes the test_get_dashboard_changed_on test
2021-11-23 11:45:32 -03:00
Long Le Xich bc855f4040
fix(hive): Update _latest_partition_from_df in HiveEngineSpec to work on tables with multiple indexes (#14302)
* Fix _latest_partition_from_df in HiveEngineSpec

* Add test HiveEngineSpec._latest_partition_from_df

* Fix formatting to pass black

Co-authored-by: Ville Brofeldt <ville.v.brofeldt@gmail.com>
2021-11-23 10:07:47 +02:00
ofekisr 16e012fe5d
refactor(chart.commands): separate commands into two different modules (#17509)
refactor: move imports under TYPE_CHECKING
2021-11-22 19:57:52 +02:00
Kamil Gabryjelski 1f8eff72de
fix: Always use temporal type for dttm columns [ID-2] (#17458)
* fix: Always use temporal type for dttm columns

* move inference and implement in chart postproc

* fix test

* fix test case

Co-authored-by: Ville Brofeldt <ville.v.brofeldt@gmail.com>
2021-11-22 15:40:38 +01:00
ofekisr 66d756955b
refactor(QueryContext): separate all processing concerns into QueryContextProcessor (#17497) 2021-11-22 10:01:01 +02:00
Rafał Ganczarek 8da982bc7c
fix(presto): expand data with null item (#17470)
* fix(presto): expand data with null item

* Fixed pre-commit check
2021-11-21 20:10:35 +02:00
AAfghahi 69c3cc712d
chore(sql_lab): Added Unit Test for stop query exception (#17464)
* added unit test

* feedback implemented
2021-11-19 12:58:12 -05:00
Daniel Vaz Gaspar 69f9ee8f5e
fix: feature flags typing (#15254)
* fix: feature flags typing

* fix tests

* add note in UPDATING.md

* fix frontend

* also move SCHEDULED_QUERIES to top level

* fix test

Co-authored-by: Ville Brofeldt <ville.v.brofeldt@gmail.com>
2021-11-19 15:56:16 +00:00
ofekisr 683d1dab13
refactor(QueryObject): decouple from superset (#17479)
* refactor: queryObject - decouple from superset

* refactor: queryObject - decouple from superset
2021-11-18 19:53:56 +02:00
ofekisr 377db1bd71
refactor: queryObject - add QueryObjectFactory (#17466) 2021-11-18 17:38:17 +02:00
binome74 211b32a4cd
fix(mssql): week time grain should respect datefirst setting (#10811)
* "P1W" grain should respect DATEFIRST setting in MS SQL Server

* Added "week_start_sunday" and "week_start_monday" grains support. Adjusted the "week" grain for better backward compatibility with MS SQL 2005/2008.

* Stylistic and linter-requested changes

* fix test

Co-authored-by: Valeriy Aleksashkin <v.aleksashkin@gmail.com>
Co-authored-by: Ville Brofeldt <ville.v.brofeldt@gmail.com>
2021-11-16 09:36:37 +02:00
Ville Brofeldt e2a429b0c8
feat(explore): adhoc column expressions [ID-3] (#17379)
* add support for adhoc columns to api and sqla model

* fix some types

* fix duplicates in column names

* fix more lint

* fix schema and dedup

* clean up some logic

* first pass at fixing viz.py

* Add frontend support for adhoc columns

* Add title edit

* Fix showing custom title

* Use column name as default value in sql editor

* fix: Adds a loading message when needed in the Select component (#16531)

* fix(tests): make parquet select deterministic with order by (#16570)

* bump emotion to help with cache clobbering (#16559)

* fix: Support Jinja template functions in global async queries (#16412)

* Support Jinja template functions in async queries

* Pylint

* Add tests for async tasks

* Remove redundant has_request_context check

* fix: impersonate user label/tooltip (#16573)

* docs: update for small typos (#16568)

* feat: Add Aurora Data API engine spec (#16535)

* feat: Add Aurora Data API engine spec

* Fix lint

* refactor: sql_json view endpoint: encapsulate ctas parameters (#16548)

* refactor sql_json view endpoint: encapsulate ctas parameters

* fix failed tests

* fix failed tests and ci issues

* refactor sql_json view endpoint: separate concern into ad hod method (#16595)

* feat: Experimental cross-filter plugins (#16594)

* fix:fix get permission function

* feat: add cross filter chart in charts gallery under FF

* chore(deps): bump superset-ui to 0.18.2 (#16601)

* update type guard references

* fix imports

* update series_columns schema

* Add changes that got lost in rebase

* Use current columns name or expression as sql editor init value

* add integration test and do minor fixes

* Bump superset-ui

* fix linting issue

* bump superset-ui to 0.18.22

* resolve merge conflict

* lint

* fix select filter infinite loop

* bump superset-ui to 0.18.23

* Fix auto setting column popover title

* Enable adhoc columns only if UX_BETA enabled

* put back removed test

* Move popover height and width to constants

* Refactor big ternary expression

Co-authored-by: Kamil Gabryjelski <kamil.gabryjelski@gmail.com>
Co-authored-by: Michael S. Molina <70410625+michael-s-molina@users.noreply.github.com>
Co-authored-by: Elizabeth Thompson <eschutho@gmail.com>
Co-authored-by: Rob DiCiuccio <rob.diciuccio@gmail.com>
Co-authored-by: Beto Dealmeida <roberto@dealmeida.net>
Co-authored-by: joeADSP <75027008+joeADSP@users.noreply.github.com>
Co-authored-by: ofekisr <35701650+ofekisr@users.noreply.github.com>
Co-authored-by: simcha90 <56388545+simcha90@users.noreply.github.com>
2021-11-15 12:50:08 +02:00
ofekisr 5d3e1b5c2c
refactor: ChartDataCommand into two separate commands (#17425) 2021-11-15 01:00:08 +02:00
ofekisr d8851c9a89
refactor(TestChartApi): move chart data api tests into TestChartDataApi (#17407)
* refactor charts api tests

* move new added test

* refactor charts api tests
2021-11-14 23:35:23 +02:00
Ville Brofeldt ad8a7c42f9
fix: avoid escaping bind-like params containing colons (#17419)
* fix: avoid escaping bind-like params containing colons

* fix query for mysql

* address comments
2021-11-13 09:01:49 +02:00
Elizabeth Thompson f10bc6d8fe
fix: add fallback and validation for report and cron timezones (#17338)
* add fallback and validation for report and cron timezones

* add logging to exception catch

* Run black

Co-authored-by: Beto Dealmeida <roberto@dealmeida.net>
2021-11-12 12:28:17 -08:00
John Bodley bcef8fa13b
feature: Add quarter unit to datetrunc (#17416)
Co-authored-by: John Bodley <john.bodley@airbnb.com>
2021-11-12 09:46:55 -08:00
ofekisr 9ce6b7de83
refactor ChartDataCommand - separate loading query_context form cache into different module (#17405) 2021-11-12 14:44:21 +02:00
ofekisr 45480f7ae5
refactor move ChartDataResult enums to common (#17399) 2021-11-11 11:41:37 +02:00
Francesco Frassinelli 0d77f36679
fix: handle TIME column serialization (#16869)
* Add support for datetime.time in json_int_dttm_ser

* Test base_json_conv support for datetime.time

* Group types by conversion function for JSON dump
2021-11-11 10:35:00 +02:00
Christian Pfarr 333b1371f7
feat: Drill ODBC/JDBC Impersonation feature (#17353)
* Added Drill ODBC Impersonation feature and necessary translations/docs

* Code Cleanup

* add jdbc impersonation_target parameter

* add unittests for DrillEngineSpec.modify_url_for_impersonation method

* reformat test_drill.py with black formatter

* run pre-commit locally

Co-authored-by: Christian Pfarr <Christian.Pfarr@deutschebahn.com>
Co-authored-by: Christian Pfarr <z0ltrix+gitlab@pm.me>
2021-11-10 08:45:16 +02:00
Kamil Gabryjelski fa51b3234e
fix(dashboard): Return columns and verbose_map for groupby values of Pivot Table v2 [ID-7] (#17287)
* fix(dashboard): Return columns and verbose_map for groupby values of Pivot Table v2

* Refactor

* Fix test and lint

* Fix test

* Refactor

* Fix lint
2021-11-05 16:05:48 +01:00
Hugh A. Miles II e5fe18660c
fix: Show sqllab state when deleting databases (#17331)
* saving

* fix ts

* update test

* update test

* log unit

* updated test
2021-11-04 20:17:08 -04:00
Beto Dealmeida 1fbce88a46
fix: set correct schema on config import (#16041)
* fix: set correct schema on config import

* Fix lint

* Fix test

* Fix tests

* Fix another test

* Fix another test

* Fix base test

* Add helper function

* Fix examples

* Fix test

* Fix test

* Fixing more tests
2021-11-04 11:09:08 -07:00
Beto Dealmeida 03a2c6ee8a
feat: apply d3NumberFormat to table reports (#17336) 2021-11-04 08:18:01 -07:00
John Bodley 36f489eea0
fix: Normalize prequery result type (#17312)
Co-authored-by: John Bodley <john.bodley@airbnb.com>
2021-11-03 13:58:40 -07:00
Beto Dealmeida cb34a22684
fix: import should accept old keys (#17330)
* fix: import should accept old keys

* Fix lint

* Preserve V1 schema
2021-11-03 11:25:30 -07:00
Geido 2199ef2dd7
chore: Test cases for annotations and annotation layers incorrect creation through API (#17246)
* Add/Refactor tests

* Add return type

* Update api tests
2021-11-03 09:11:41 +00:00
Beto Dealmeida 93bafa0e6a
feat: improve logic in is_select (#17329)
* feat: improve logic in is_select

* Add more edge cases
2021-11-02 17:30:12 -07:00
Étienne Boisseau-Sierra f0c0ef7048
fix(cli): fail CLI script on failed import/export (#16976)
* Test that failing export or import is done properly

For each CLI entry-point we will modify, we make sure that:

- a failing process exits with a non-0 exit code,
- an error is logged.

Signed-off-by: Étienne Boisseau-Sierra <etienne.boisseau-sierra@unipart.io>

* Exit process with error if export/import failed

Bubble exception up when failing import or export

During a CLI import or export of dashboards, if the process fails, the
exception it caught and a simple message is sent to the logger.
This makes that from a shell point of view, the script was successfull —
cf. #16956.

To prevent this, we want to ensure that the process exits with an error
(i.e., a non-0 exit-code) should the export or import fail mid-flight.

Signed-off-by: Étienne Boisseau-Sierra <etienne.boisseau-sierra@unipart.io>
2021-10-29 08:56:29 +01:00
Ville Brofeldt 4316fe6ae6
fix(annotataion): handle required fields properly (#17234) 2021-10-27 08:42:28 +03:00
Shiva Raisinghani ef3afbde82
refactor: Repeated boilerplate code between upload to database forms (#16756)
* abstract boilerplate code into class and rename csv to file

* add db migration

* fix some stuff

* more renaming of csv to file

* rename in translations

* update down revision

* update down revision

* bump chart version

* switch to alter column name approach in db migration

* fix db migration for MySQL

* db migration conflict
2021-10-25 13:53:06 +03:00
Yongjie Zhao 4f1d202430
chore: use official isort in pre-commmit (#17215) 2021-10-25 17:57:38 +08:00
Yongjie Zhao bedb8f4dff
fix(bigquery): calculated column cannot orderby in BigQuery (#17196)
* fix(bigquery): calculated column cannot orderby in BigQuery

* typo

* add ut

* fix lint
2021-10-22 22:42:58 +08:00
Yongjie Zhao 4c708af710
fix: avoid filters containing null value (#17168) 2021-10-21 18:20:38 +08:00
Amit Miran 029ed90afb
fix: preventing sql lab None limit value (#17155)
* fix: preventing sql lab None limit value

* test: create a test for the fix

* pylint (#17172)

* add test (#17173)

Co-authored-by: Hugh A. Miles II <hughmil3s@gmail.com>
2021-10-20 23:43:14 +03:00
Ville Brofeldt d7834f17e3
fix(filter-indicator): show filters handled by jinja as applied (#17140) 2021-10-18 19:28:05 +02:00
John Bodley 565ee2318d
chore(druid): Explicitly cast col to TIMESTAMP (#17101)
Co-authored-by: John Bodley <john.bodley@airbnb.com>
2021-10-18 10:06:04 -07:00
Beto Dealmeida 83a2f8346e
chore: enable BQ tests (#17017) 2021-10-14 08:07:47 -07:00
John Bodley b9ff85d9ea
chore(engine): Translate fractional time grains—requires @superset-ui bump (#17078)
* chore(engine): Translate fractional time grains

* Bump @superset-ui

Co-authored-by: John Bodley <john.bodley@airbnb.com>
2021-10-12 21:40:48 -07:00
John Bodley 5e85f48515
chore(druid): Standardizing time grain transformations (#17050)
* chore(druid): Standardizing time grain transformations

* Update druid_tests.py

* Update druid_tests.py

Co-authored-by: John Bodley <john.bodley@airbnb.com>
2021-10-12 08:34:28 -07:00
Elizabeth Thompson c2e1ab6550
add logging on successful data uploads (#17065) 2021-10-11 16:28:07 -07:00
Yongjie Zhao fd8461406d
fix: rolling and cum operator on multiple series (#16945)
* fix: rolling and cum operator on multiple series

* add UT

* updates
2021-10-07 16:42:08 +08:00
Beto Dealmeida c993c5845f
fix(BigQuery): explicitly quote columns in select_star (#16822)
* fix (BigQuery): explicitly quote columns in select_star

* Fix test

* Fix SELECT * in BQ

* Add unit tests

* Remove type changes
2021-10-06 07:43:32 -07:00
Yongjie Zhao 387ac2b6d3
fix: replace absolute difference with difference in compareOperator (#16930)
* fix: replace absolute difference with difference in compareOperator

* fix ut
2021-10-04 13:31:19 +08:00
ofekisr 0d0c759cfe
refactor: sql lab command: separate concerns into different modules (#16917)
* chore move sql_execution_context to sqllab package

* add new helper methods into base Dao

* refactor separate get existing query concern from command

* refactor separate query access validation concern

* refactor separate get query's database concern from command

* refactor separate get query rendering concern from command

* refactor sqllab_execution_context

* refactor separate creating payload for view

* chore decouple command from superset app

* fix pylint issues

* fix failed tests

* fix pylint issues

* fix failed test

* fix failed black

* fix failed black

* fix failed test
2021-10-03 11:15:46 +03:00
apurva-sigmoid 420eff42b8
feat: add Firebolt DB engine spec (#16903)
* New branch from superset for integration with firebolt sqlalchemy adapter

* Added db_engine_spec file for Firebolt

* Removed firebolt code from superset repo

* Deleted virtual env commit

* Adding time grain changes to firebolt.py

* Updated README.md

Added steps to install and run Superset with Firebolt SQLAlchemy Adapter

* Update README.md

Reduced installation steps. Using PyPi installation for adapter now

* Revert "Update README.md"

This reverts commit 5ed17c7a45.

* Revert "Updated README.md"

This reverts commit 45c5072649.

* added epoch methods, added test cases for firebolt db engine spec and edited setup.py

* Added license to files

* Added documentation for Firebolt-SQLAlchemy

* Removed trailing whitespace

Co-authored-by: raghavsharma <raghavs@sigmoidanalytics.com>
Co-authored-by: raghavSharmaSigmoid <88667094+raghavSharmaSigmoid@users.noreply.github.com>
2021-10-01 19:43:15 +03:00
Yongjie Zhao 94282b7ecd
fix: time comparison can't guarantee the accuracy (#16895)
* fix: time comparison can't guarantee the accuracy

* fix multiple series

* fix lint

* fix ut

* fix lint

* more ut

* fix typo
2021-09-30 19:59:57 +08:00
AAfghahi aa747219ad
feat: Add Private Google Sheets to dynamic form (#16628)
* first pass private gsheets

* made encrypted extra into string, refactored onParametersChanged

* private sheets working, credential_info errors

* all but test connection working

* first pass private gsheets

* made encrypted extra into string, refactored onParametersChanged

* private sheets working, credential_info errors

* all but test connection working

* Regenerate package-lock.json

Co-authored-by: Beto Dealmeida <roberto@dealmeida.net>
2021-09-28 17:08:50 -07:00
Ville Brofeldt 0f16177bde
fix(native-filters): ignore unset filter box time range (#16854) 2021-09-27 17:17:52 +03:00
ofekisr c520eb79b0
refactor: sqllab: move sqllab ralated enumns and utils to more logical place (#16843)
* refactor move QueryStatus to common

* refactor move apply_display_max_row_limit to sqllab package

* refactor move limiting_factor to sqllab package

* fix pylint issues
2021-09-26 21:15:57 +03:00
ofekisr 84f7614e97
feat(filter-set): Add filterset resource (#14015)
* Add filterset resource

* fix: fix pre-commit

* add tests

* add tests and fixes based of failures

* Fix pre-commit errors

* chore init filterset resource under ff constraint

* Fix migration conflicts

* Fix pylint and migrations issues

* Fix pylint and migrations issues

* Fix pylint and migrations issues

* Fix pylint and migrations issues

* Fix pylint and migrations issues

* Fix pylint and migrations issues

* Fix pylint and migrations issues

* Fix pylint and migrations issues

* Fix pylint and migrations issues

* Fix pylint and migrations issues

* Fix pylint and migrations issues

* add tests and fixes based of failures

* Fix missing license

* fix down revision

* update down_revision

* fix: update down_revision

* chore: add description to migration

* fix: type

* refactor: is_user_admin

* fix: use get_public_role

* fix: move import to the relevant location

* chore: add openSpec api schema

* chore: cover all openspec API

* fix: pre-commit and lint

* fix: put and post schemas

* fix: undo superset_test_config.py

* fix: limit filterSetsApi to include_route_methods = {"get_list", "put", "post", "delete"}

* renaming some params

* chore: add debug in test config

* fix: rename database to different name

* fix: try to make conftest.py harmless

* fix: pre-commit

* fix: new down_revision ref

* fix: bad ref

* fix: bad ref 2

* fix: bad ref 3

* fix: add api in initiatior

* fix: open spec

* fix: convert name to str to include int usecases

* fix: pylint

* fix: pylint

* Update superset/common/request_contexed_based.py

Co-authored-by: Ville Brofeldt <33317356+villebro@users.noreply.github.com>

* chore: resolve PR comments

* chore: resolve PR comments

* chore: resolve PR comments

* fix failed tests

* fix pylint

* Update conftest.py

* chore remove BaseCommand to remove abstraction

* chore remove BaseCommand to remove abstraction

* chore remove BaseCommand to remove abstraction

* chore remove BaseCommand to remove abstraction

* chore fix migration

Co-authored-by: Ofeknielsen <ofek.israel@nieslen.com>
Co-authored-by: amitmiran137 <amit.miran@nielsen.com>
Co-authored-by: Amit Miran <47772523+amitmiran137@users.noreply.github.com>
Co-authored-by: Ville Brofeldt <33317356+villebro@users.noreply.github.com>
2021-09-23 11:27:59 +03:00
Phillip Kelley-Dotson a198dbb19b
feat: add certifiedby & certification details fields to the edit dataset columns fields (#16454)
* add migration

* add backend and frontend for certified

* update migration with batch

* fix integration test and update Updating.md

* Update superset-frontend/src/datasource/DatasourceEditor.jsx

Co-authored-by: Geido <60598000+geido@users.noreply.github.com>

* Update superset-frontend/src/datasource/DatasourceEditor.jsx

Co-authored-by: Geido <60598000+geido@users.noreply.github.com>

* Update superset-frontend/src/datasource/DatasourceEditor.jsx

Co-authored-by: Geido <60598000+geido@users.noreply.github.com>

* change method name

* add tooltip info

* add mixin

* merge heads

* address comments

* fix select label styles

* add extra field

* fix test?

* add extra field to put schema

Co-authored-by: Geido <60598000+geido@users.noreply.github.com>
2021-09-22 15:09:30 -07:00
Michael S. Molina 596e1cdf9b
refactor: Changes the DatabaseSelector and TableSelector to use the new Select component (#16483) 2021-09-22 07:43:46 -03:00
Beto Dealmeida 48a61bacc5
fix: handle CTEs with comments on is_select (#16769) 2021-09-21 16:23:54 -07:00
Elizabeth Thompson 2a25e2d7ca
update execution logs and states for alerts (#16736) 2021-09-20 14:26:30 -07:00
Yongjie Zhao cc1c6c1bb6
feat: add resample operator in post processing (#16607)
* feat: add resample operator in post processing

* wip

* fill zero values

* updates

* fix ut
2021-09-17 16:40:59 +08:00
Ville Brofeldt 4e3d4f6daf
feat: add global max row limit (#16683)
* feat: add global max limit

* fix lint and tests

* leave SAMPLES_ROW_LIMIT unchanged

* fix sample rowcount test

* replace max global limit with existing sql max row limit

* fix test

* make max_limit optional in util

* improve comments
2021-09-16 19:33:41 +03:00
Ville Brofeldt a839649e5c
fix(pandas-postprocessing): percentage compare to use correct column (#16716) 2021-09-16 13:29:58 +03:00
Ville Brofeldt 836b5e2c86
feat: add support for generic series limit (#16660)
* feat: add support for generic series limit

* refine series_columns logic

* update docs

* bump superset-ui

* add note to UPDATING.md

* remove default value for timeseries_limit
2021-09-16 12:09:08 +03:00
Yongjie Zhao 21f98ddc21
fix: catch exception when create connection (#16692)
* fix: catch exception when create connection

* fix lint

* added UT
2021-09-16 15:55:57 +08:00
Beto Dealmeida 092ef5bdfc
fix: set importer as owner (#16656)
* fix: set importer as owner

* Fix tests
2021-09-15 12:27:02 -07:00
Ville Brofeldt 88c09c2138
feat(jinja): improve url parameter formatting (#16711)
* feat(jinja): improve url parameter formatting

* add UPDATING.md

* fix test
2021-09-15 20:00:26 +03:00
John Bodley fb4650a6eb
chore(pylint): Remove top-level disable (#16589)
* chore(pylint): Remove top-level disable

* Update examples.py

* Update command.py

Co-authored-by: John Bodley <john.bodley@airbnb.com>
2021-09-15 09:30:23 -07:00
aniaan 9e00e4e8cc
fix(dataset): create ES-View dataset raise exception #16623 (#16624)
* fix(dataset): create es-view dataset raise exception #16623

* fix(database): fix has_view logic

* refactor(database): fix logic

* style(lint): remove unused typing

* fix(test): add test case

* fix(test): fix test case
2021-09-14 22:29:29 +08:00
Daniel Vaz Gaspar f2bc139e35
feat: feature flag configurable custom backend (#16618)
* feat: feature flag configurable custom backend

* fix lint

* simpler approach

* fix tests

* revert dependency updates

* Update superset/utils/feature_flag_manager.py

Co-authored-by: Ville Brofeldt <33317356+villebro@users.noreply.github.com>

* Update superset/config.py

Co-authored-by: Ville Brofeldt <33317356+villebro@users.noreply.github.com>

Co-authored-by: Ville Brofeldt <33317356+villebro@users.noreply.github.com>
2021-09-13 14:09:53 +01:00
Jack Fragassi 4dc859f89e
fix: Ensure alerts & reports aren't schduled when flag is off (#16639)
* Don't schedule alerts & reports when flag is off

* Fix test function name

* Fix test

* Oops

* Another tweak

* Try to lint by hand

* Fix mock
2021-09-10 13:37:21 +01:00
天河 bb014b5131
fix: fix assignment in FilterBoxViz (#16662)
* Fixing assignment.

Signed-off-by: tianhe1986 <w1s2j3229@163.com>

* Adding unit test for FilterBoxViz.

Signed-off-by: tianhe1986 <w1s2j3229@163.com>

* Reformatting with black.

Signed-off-by: tianhe1986 <w1s2j3229@163.com>

* Revert format change in other test.

Signed-off-by: tianhe1986 <w1s2j3229@163.com>

* Reformatting with the same black version with pre-commit config.

Signed-off-by: tianhe1986 <w1s2j3229@163.com>
2021-09-10 15:10:55 +03:00
AAfghahi c66f278b42
feat: Backend Validation for Creation Method (#16375)
* backend creation method validation

* added tests

* Update superset/reports/dao.py

Co-authored-by: Beto Dealmeida <roberto@dealmeida.net>

* Update superset/reports/dao.py

Co-authored-by: Beto Dealmeida <roberto@dealmeida.net>

* Update tests/integration_tests/reports/api_tests.py

Co-authored-by: Beto Dealmeida <roberto@dealmeida.net>

* Update tests/integration_tests/reports/api_tests.py

Co-authored-by: Beto Dealmeida <roberto@dealmeida.net>

* Update superset/reports/dao.py

Co-authored-by: Beto Dealmeida <roberto@dealmeida.net>

* Update superset/reports/dao.py

Co-authored-by: Beto Dealmeida <roberto@dealmeida.net>

* Update superset/reports/commands/create.py

Co-authored-by: Beto Dealmeida <roberto@dealmeida.net>

* Update superset/reports/commands/exceptions.py

Co-authored-by: Beto Dealmeida <roberto@dealmeida.net>

* revisions

Co-authored-by: Beto Dealmeida <roberto@dealmeida.net>
2021-09-08 16:35:18 -07:00
Ville Brofeldt 9de2196b7f
fix: TemporalWrapperType string representation (#16614)
* fix: TemporalWrapperType string representation

* fix tests
2021-09-07 13:50:24 +03:00
ofekisr e60b489867
refactor sql_json view endpoint: separate concern into ad hod method (#16595) 2021-09-05 23:18:17 +03:00
ofekisr be77ad2288
refactor: sql_json view endpoint: encapsulate ctas parameters (#16548)
* refactor sql_json view endpoint: encapsulate ctas parameters

* fix failed tests

* fix failed tests and ci issues
2021-09-05 16:34:26 +03:00
Rob DiCiuccio 4e380db3fd
fix: Support Jinja template functions in global async queries (#16412)
* Support Jinja template functions in async queries

* Pylint

* Add tests for async tasks

* Remove redundant has_request_context check
2021-09-03 14:33:29 +03:00
Ville Brofeldt 070fdbeebc
fix(tests): make parquet select deterministic with order by (#16570) 2021-09-02 15:16:33 -03:00
Shiva Raisinghani d25b0967a1
feat: Add parquet upload (#14449)
* allow csv upload to accept parquet file

* fix mypy

* fix if statement

* add test for specificying columns in CSV upload

* clean up test

* change order in test

* fix failures

* upload parquet to seperate table in test

* fix error message

* fix mypy again

* rename other extensions to columnar

* add new form for columnar upload

* add support for zip files

* undo csv form changes except usecols

* add more tests for zip

* isort & black

* pylint

* fix trailing space

* address more review comments

* pylint

* black

* resolve remaining issues
2021-08-31 10:20:25 +03:00
Erik Ritter 8adc31d14c
Revert "chore: Changes the DatabaseSelector to use the new Select component (#16334)" (#16478)
This reverts commit c768941f2f.
2021-08-26 22:28:04 -03:00
Ville Brofeldt 35864748f2
fix(explore): retain chart ownership on query context update (#16419) 2021-08-24 18:37:34 +03:00
Ville Brofeldt f6637cac7d
fix(api): return total count on related endpoint (#16397)
* fix(api): return total count on related endpoint

* update response code from 400 to 422
2021-08-24 15:07:58 +03:00
Michael S. Molina c768941f2f
chore: Changes the DatabaseSelector to use the new Select component (#16334) 2021-08-23 15:41:03 -03:00
Beto Dealmeida adebc0997b
fix: update table ID in query context on chart import (#16374)
* fix: update table ID in query context on chart import

* Fix test
2021-08-20 10:03:31 -07:00
Hugh A. Miles II 50d896f1b7
fix: Fix parsing onSaving reports toast when user hasn't saved chart (#16330)
* don't maniuplate error message

* remove extra idx reference

* u

* change print

* update with test

* add case for dashboards

* fix test
2021-08-19 14:04:23 -04:00
Beto Dealmeida afb8bd5fe6
feat: improve embedded data table in text reports (#16335)
* feat: improve HTML table in text reports

* Remove unused import

* Update tests

* Fix test
2021-08-18 17:00:29 -07:00
Beto Dealmeida ac8e54d909
fix: improve pivot post-processing (#16289)
* fix: improve pivot post-processing

* Add tests

* Trim space from column name
2021-08-17 14:41:22 -07:00
Ville Brofeldt 36abc51f90
fix(dashboard): unset empty time filter indicator (#16272) 2021-08-16 19:32:05 +03:00
Ville Brofeldt d46dc9aa45
chore: upgrade mypy and add type guards (#16227) 2021-08-14 06:31:45 +03:00
John Bodley 24b43beff9
chore(pylint): Bump Pylint to 2.9.6 (#16146)
Co-authored-by: John Bodley <john.bodley@airbnb.com>
2021-08-14 10:32:28 +12:00
Michael S. Molina 720e5b111a
chore: Shows the dataset description in the gallery dropdown (#16200)
* chore: Shows the dataset description in the gallery dropdown

* chore: Adjusts the tooltip positioning, fixes the search and removes unnecessary bootstrap data
2021-08-13 15:08:12 -03:00
Yongjie Zhao 6cd15d54a0
refactor: external metadata fetch API (#16193)
* refactor: external metadata api

* fix comments

* fix ut

* fix fe lint

* fix UT

* fix UT
2021-08-13 20:56:42 +08:00