Commit Graph

6564 Commits

Author SHA1 Message Date
Lily Kuang df6efb6aa2
feat: alert/report execution log list view (#11937) 2020-12-10 15:15:13 -08:00
Beto Dealmeida 475f59cb1c
feat: confirm overwrite when importing (#11982)
* feat: confirm overwrite when importing

* Skip flaky test
2020-12-10 14:50:10 -08:00
Beto Dealmeida 9e07e10055
chore: move passwords needed message (#12002) 2020-12-10 11:47:54 -08:00
Michael S. Molina 3a6254184a
refactor: Removes hard coded colors (#11977)
* Removes hard coded colors

Removes hard coded colors defined in src/components/styles.ts. The colors defined in this file were used only in the Select component so they were migrated to src/components/Select/styles.tsx and ajusted to conform to the theme colors.

* Use theme context for Select styles

* Includes Theme Provider in tests with Select
2020-12-10 11:43:57 -08:00
Beto Dealmeida 9256b6fb3d
chore: consolidate common code in importers (#11936)
* chore: consolidate common code in importers

* Small fixes

* Small fixes
2020-12-10 10:11:58 -08:00
Victor Malai 38bb6f3f20
fix : Fix style for header (sqllab) (#11980)
* Fix style for header

* flex

* Refactor

* Remove styled from import

* Change width of container

* Add tooltip and set fixed width of sidebar

* Fix lint

Co-authored-by: Victor Malai <victormalai@Victors-MacBook-Pro.local>
2020-12-09 23:34:43 -08:00
Mayur Newase 8cc566792a
fix(explore): changing metric aggregate doesn't update label (#11946)
* fix: [chart]heatmap selecting metrics does not update the query results
fixes issue #11866
title's label is overriding metric label.

* Using custom label to decide label of metrics.

* lint

* Tests fixed

* early metric label check while saving from ui

* early custom label check

* removed extra space

* no state mutations

* simplify

* removed log

* nned to fix linting issue

* Lint fixed
2020-12-10 09:30:57 +02:00
Evan Rusackas c73904b02e
fixing rounded corners (#11990) 2020-12-09 21:07:23 -08:00
Victor Malai 5435064807
refactor : Transform FilterScopeModal to Typescript (#11964)
* Transform from jsx to tsx

* replace any with void

Co-authored-by: Victor Malai <victormalai@Victors-MacBook-Pro.local>
2020-12-09 15:46:06 -08:00
Victor Malai e62cf0d84d
fix : adhoc filter dropdown (#11963)
* Add z-index to popover

* Fix prettier

* Fix closing popover on select from dropdown

* Fix prettier

* Fix visibility change

Co-authored-by: Victor Malai <victormalai@Victors-MacBook-Pro.local>
2020-12-09 15:44:20 -08:00
Kamil Gabryjelski 6fe1f9d78a
Debounce TextControl if change runs immediately after input (#11985) 2020-12-09 15:41:44 -08:00
Kamil Gabryjelski a4b06d23fd
Change paddings on ListView and SubMenu (#11975) 2020-12-09 15:08:59 -08:00
Elizabeth Thompson 3c177e550b
add user to sql lab state (#11986) 2020-12-09 14:53:15 -08:00
Beto Dealmeida 36976d17f7
fix: make "DELETE" confirmation work in other languages (#11987)
* Confirm delete i18n

* Make DELETE a parameter
2020-12-09 14:40:07 -08:00
Kasia Kucharczyk 4da47f1635
tests: added fixture with energy usage instead of example (#11308)
* Added energy usage fixture. Updated dashboard utils and unicode fixture with new method parameters.

* Add energy fixture to tests/access_tests.py

* Add energy fixture to tests/core_tests.py

* Add energy fixture to tests/dashboard_tests.py

* Add energy fixture to tests/datasets/api_tests.py

* Add energy fixture to tests/db_engine_specs/base_engine_spec_tests.py

* Add energy fixture to tests/import_export_tests.py

* Add energy fixture to tests/model_tests.py

* Add energy fixture to tests/query_context_tests.py

* Add energy fixture to tests/security_tests.py

* Add energy fixture to tests/charts/api_tests.py

* Changed formatting of slices' parameters in energy usage fixture

* Removed loading energy udage data from test conf file

* Add energy fixture to tests/databases/api_tests.py

* Fixes after review: removed isort:skip, load_charts->load_energy_charts, removed unused import.

* Added energy fixture to tests/charts/commands_tests.py and retrieving proper Slice by name

* Fixed charts/api_tests.py to use energy_usage from fixtures

* Fixed datasets/commands_tests.py to retrieve dataset by name and use energy_usage fixture

* Changed energy usage data to generated data and fixed chart tests which was checking energy usage data
2020-12-09 12:02:29 -08:00
David Aaron Suddjian 6270fa2026
refactor: Upgrade Redux (#11967)
* upgrade redux and react-redux, adjust types

* first round of test fixes

* fix rest of unit tests

* lint

Co-authored-by: Phillip Kelley-Dotson <pkelleydotson@yahoo.com>
2020-12-09 11:58:42 -08:00
Jesse Yang 9121482479
refactor: move enums to the beginning of utiuls/core.py (#11883) 2020-12-09 11:04:09 -08:00
Daniel Vaz Gaspar 1e3aaab590
fix(reports): validator_config, report state machine, working_timeout (#11890)
* fix(reports): expect more exceptions and fix validator config

* use a state pattern on command reports

* use a state pattern on command reports continue

* fix multiple heads

* fix unittests

* add more tests

* fix api tests after enum rename

* fix alembic multiple heads

* fix tests

* fix fixture cleanup

* fix mysql tests

* fix initial and not found state

* fix schema, and private public methods, addressing comments

* add new col to the API
2020-12-09 18:19:07 +00:00
Maxime Beauchemin 150c8e36b1
fix: always fetch database list on bootstrap payload (#11934)
There was this weird bug happening only when `SQLLAB_BACKEND_PERSISTENCE
= False` where if no database had been selected, there would be some
issue.

This makes sure that the store is populated consistently with the list
of database connections regardless of `SQLLAB_BACKEND_PERSISTENCE`. It
also uses the DAO to fetch database and will apply the RBAC-related
filters if any, the same way that the API does.
2020-12-09 09:36:18 -08:00
Hugh A. Miles II cc44a2c01b
feat: Sqllab to Explore UX improvements (#11755)
* create boiler modal component

* hello world modal

* setup modal flow

* setup savemodal for components

* flake8

* fix onclick reference

* working create datasource boiler

* saving spot for callback on text input

* working dataset with input box

* working redirect on completion

* get data for owners dropdown

* fix build with pull from master

* fix the filteroption

* 💯

* move state to upper component

* add overwrite state

* hacked overwrite process

* linting

* fix filter

* cleaning up the coe

* Delete preset.code-workspace

* remove unused code

* remove visualize

* update default value

* remove unneeded vars

* checkout package-lock.json

* linting

* get user id

* remove page filter

* setup proper call for updating columns in dataset

* add move to explore flow

* linting

* add param for overriding columns

* linting

* change title

* fix some tings

* cleanup

* linting

* add types in some places

* save toast

* use moment

* add error toast

* create enum for radio states

* initial state for saving query

* add tpying

* addressing concerns

* update propTypes

* add functionality for CTAS explor btn

* handle CTAS state

* fix onclick to reference upper level component

* formatting

* reset state after closing

* add error message when user doesn't pick an already selected dataset

* remove unneeded todo

* remove styling

* move async calls to api directory

* remove console.log

* add user id param

* typing

* littty

* move put to seperate file

* save

* dsf

* fix typing errors

* adding more types

* fix typing erros

* linting

* add basic spec test

* create dataset modal

* add components reference

* Rename SaveDatasetModal_spec.jsx to SaveDatasetModal_spec.tsx

* remove sinon for now

* fix typing errors on modal files

* fix linting

* address comments

* attempt to fix linting

* add props

* fix test

* fix the linting

* yerp

* fix this references

* spaces

* handleOverwriteCancel reference cleanup

* rename bool value for shouldOverwriteDataset

* fix typing for onChange

* you still the best in the world

* fix spec

* align branches

* push

* fix key names

* fix dataset reference

* lowercase

* fix save bug with tiem

* fixed styling

* fix date state after push to explore

* add disabling states

* plz refactor this

* this is working fully now

* do some renaming

* renaming

* remove console.logs

* still refactoring

* remove unneeded code

* remove unneeded variables

* still cleaning

* added interface

* fix typing issues

* cleanup unused code

* fix npm lnit

* fix initial problems

* add props to test

* remove unneeded files

* skip linting

* saving

* this works

* remove old test

* remove old test

* fix linting

* fix broken test

* remove jsx file

* refactoring

* cleanup

* remove comments

* reset user object

* fix functions

* fix this

* reverting CTAS btn flow

* remove onclick

* save frontend work

* allow for database id to be passed as param in body

* use enum

* fix linting

* style alignment

* get rid of .then

* add function to compute default value with tiem

* lit

* remove ts-error

* fix typing
2020-12-08 17:29:41 -08:00
Jesse Yang 8164aeafb1
build: cancel previous github action runs (#11940) 2020-12-08 15:27:08 -08:00
Daniel Vaz Gaspar 7e6f04fce4
fix(alerts, thumbnails): celery tasks using flask-sqlalchemy sessions (#11950)
* fix(alerts, thumbnails): celery tasks using flask-sqlalchemy sessions

* selenium user is case sensitive
2020-12-08 13:03:32 +00:00
Victor Malai 05258ebc6c
fix(event-flow-viz): handle null metadata selection (#11885)
* Initialize object with empty array if is multiselect, fix 500 BE error

* modify data coming
2020-12-08 08:53:26 +02:00
Beto Dealmeida 8f1ac7ead1
feat: add modal to import dashboards (#11924) 2020-12-07 21:26:14 -08:00
Beto Dealmeida 33325f9fa6
feat: add modal to import charts (#11956)
* WIP

* Splat props
2020-12-07 18:33:59 -08:00
Beto Dealmeida fbb458fa8b
feat: add modal to import datasets (#11910) 2020-12-07 16:20:25 -08:00
Beto Dealmeida 2b9695c520
feat: add modal to import databases (#11884)
* feat: add modal to import databases

* Fix test

* Improve hook

* Remove log and needless store.

* Change JS functions
2020-12-07 11:22:45 -08:00
Krist Wongsuphasawat a7bba92469
chore: bump nvd3 plugin version (#11947) 2020-12-07 12:19:03 +07:00
Daniel Vaz Gaspar 14ea444e58
fix(charts): screenshot API declaring an unnecessary rison arg (#11931) 2020-12-05 08:57:44 +00:00
Daniel Vaz Gaspar f98ae014fa
feat(releasing): support changelog csv export (#11893)
* feat(releasing): support changelog csv export

* fix lint and type annotations
2020-12-05 08:55:31 +00:00
Kamil Gabryjelski 41738df77d
feat: Results table on Explore view (#11854)
* Upgrade react-split

* Implement split on ExploreChartPanel

* Implement tabs with collapse

* Fix run query button

* Fix copy to clipboard button

* Move table controls to separate file

* Make component more generic to handle samples

* Remove samples from DisplayQueryButton

* Move data tables to separate file

* Make split dynamically controlled

* Fix unit test

* Fix arrow not centered

* fixup! Fix arrow not centered

* Change copy button paddings

* Use translations

* Fix grammar in a comment

* Fix imports

* Use grid units

* Convert new files to typescript

* Fix after rebase

* Remove forceRender

* Fix big_number test

* Delay making request until panel is opened

* White background in south panel

* fixup! White background in south panel

* Lint fix

* Lint fix

* Remove redundant prop types

* Remove console log

* Delay loading samples until user switches tab

* Add debounce to filter input

* Use gridUnit for gutter sizes

* Change types object to Record<string, any>
2020-12-04 19:49:24 -08:00
Beto Dealmeida 66cd565bff
feat: add Postgres SQL validator (#11538)
* Add Postgres SQL validator

* Strip line number from message

* Add unit tests

* Run tests only with postgres backend

* Add dep

* Add dep to bashlib
2020-12-04 19:17:23 -08:00
Geido 2c323426d1
refactor: Move Badge to Antdesign (#11899)
* Move Badge to Antdesign

* Export enhanced badge only

* Center number in badge
2020-12-04 17:06:54 -08:00
Victor Malai 64d6fb9f6f
refactor: Extract copy functionality to utils (#11928)
* Extract copy functionality to utils

* Refactor

* Revert bind

* WIP

* Absolute path

* Fix lint

* Remove unused resolve
2020-12-04 17:04:41 -08:00
Erik Ritter fa68288d61
fix: make sure we log the logs (#11939) 2020-12-04 16:50:16 -08:00
Craig Rueda 8adc8b8866
Quick fix for branch names in tags (#11930) 2020-12-04 14:27:25 -08:00
Kasia Kucharczyk 98dc65722c
Added check if SQL query is empty and disable shortcut for run query (#11877) 2020-12-04 10:45:43 -08:00
Lily Kuang 60122a2b2d
feat: filters for alerts and reports list view (#11900) 2020-12-04 09:58:34 -08:00
Erik Ritter 77d362d306
fix: Remove expensive logs table migration (#11920) 2020-12-04 07:59:28 -08:00
Ville Brofeldt 327a2817d3
feat: add event and interval annotation support to chart data ep (#11665)
* feat: add event and interval annotation support to chart data ep

* add tests + refactor fixtures

* use chart dao
2020-12-04 14:40:31 +02:00
Hugh A. Miles II 41d4fb9cb3
fix: Forgot to remove bad comments from SaveDatasetModal (#11919) 2020-12-03 17:03:40 -08:00
Beto Dealmeida e0288bf76b
chore: add unit tests for the current import functionality (#11786)
* chore: add unit tests for the current import functionality

* Improve comment

* Fix unit test
2020-12-03 14:48:43 -08:00
Geido 5b1939802d
refactor: Move ProgressBar to Antd (#11875)
* Move ProgressBar to Antd

* Remove trailing space

* Fix linting issues

* Export enhanced Progress only
2020-12-03 13:28:06 -08:00
Beto Dealmeida 54bf70733f
feat: run BQ queries as single statement (#11904)
* feat: run BQ queries as single statement

* Update deps

* Fix lint

* Update superset/sql_lab.py

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

Co-authored-by: Ville Brofeldt <33317356+villebro@users.noreply.github.com>
2020-12-03 13:20:23 -08:00
Elizabeth Thompson 04f993e222
fix: adjust width for non multi select inputs (#11911) 2020-12-03 11:27:17 -08:00
Hugh A. Miles II 9ae2f95b34
feat: Adding SaveDatasetModal component (#11861) 2020-12-03 11:14:44 -08:00
Bogdan 0396c705d4
chore: Support SET & SHOW commands as read only SQL commands (#11868)
* Support SET & SHOW commands as read only SQL commands

* Move is_readonly definition into the engine spec

* Rename & use super()

Co-authored-by: bogdan kyryliuk <bogdankyryliuk@dropbox.com>
2020-12-03 10:44:11 -08:00
Agata Stawarz 38d21acff6
fix: Check if annotation type is supported by the given chart type (#11876)
* Check if annotation type is supported by this kind of chart

* Check if annotation type exists
2020-12-03 10:23:23 -08:00
Evan Rusackas 53017e5a35
fix: Button storybook component size knob (#11912) 2020-12-03 10:20:24 -08:00
Evan Rusackas 38b720b0a7
style: eslint curly rule (#11913)
* style: eslint curly rule

* curly for ts
2020-12-03 10:20:05 -08:00