* Add presto to the CI
Sample test data
Datetime conversion
Sample test data
Fix tests
* TODO to switch to timestamps
* Address feedback
* Update requirements
* Add TODOs
Co-authored-by: bogdan kyryliuk <bogdankyryliuk@dropbox.com>
* refractored alerting to not pass sqlalchemy obj as args
* updated to pass only alert id as arg
* used object id instead of argument
* updated alerts_tests.py to reflect change
Co-authored-by: Jason Davis <@dropbox.com>
* fix(log): log crashes if expired or not authenticated
* fix lint and rison
* add tests
* more tests
* perm fix
* fix test not found
* JS lint
* fix Jest test
* implemented updates to alerting
* fixed imports and teardown
* changed unittest to pytest conventions
* add app_context to tests
Co-authored-by: Jason Davis <@dropbox.com>
* fix(permissions): alpha role is inconsistent
* reverse and allow Alpha to access manager menu
* Bump FAB to 3.0.1rc1 to include del permission fix
* add docs, tests and UPDATING
* EOL
* Fix query view for Alpha
* fix: API marshmallow3 drop utc for naive datetime fields
* fix: API marshmallow3 drop utc for naive datetime fields
* fix, tests
* isort and test
* black
* add and fix test
* fix comment
* fix(chart-data-api): case insensitive evaluation of filter op
* fix(chart-data-api): case insensitive evaluation of filter op
* mypy
* remove print statement
* add test
* feat(api): bump marshmallow and FAB to version 3
* revert query context tests changes
* obey mypy
* fix tests
* ignore types that collide with marshmallow
* preparing for RC2
* fix tests for marshmallow 3
* typing fixes for marshmallow
* fix tests and black
* fix tests
* bump to RC3 and lint
* Test RC4
* Final 3.0.0
* Address comments, fix tests, better naming, docs
* fix test
* couple of fixes, addressing comments
* bumping marshmallow
* Support more table properties for the hive upload
Refactor
Add tests, and refactor them to be pytest friendly
Use lowercase table names
Ignore isort
* Use sql params
Co-authored-by: bogdan kyryliuk <bogdankyryliuk@dropbox.com>
* feat: add support for alerts
* Add ModelViews
* First pass at adding scheduled Alert support
* Fix syntax errors
* Add log_retention and database to model
* Improving screenshots
* Still refactoring screenshots
* Pass down thumb_size properly
* Progress on screenshot endpoint
* Add alerts.last_eval_dttm and alert query logic
* Getting ready to split compute_screenshot and screenshot/{SHA}
* split the endpoints
* Improving alerting loop
* empty methods
* Add CLI command 'superset alert' that runs a sched loop
* Getting things to work
* email delivery
* A working email\!
* Add feature flag
* Add some description_columns to AlertModelView
* Little tweaks
* Use database.get_df, eval cells for truthiness
* Migrate thumbnail/screenshot functions to use new arg pattern
* Addressing PR feedback
* Update alerts DB migration down_revision
* Resolve _deliver_email arg conflict
* Make mypy happy
* Make isort happy
* Make pylint happy
Co-authored-by: Rob DiCiuccio <rob.diciuccio@gmail.com>
* feat: add database dropdown to dashboard import
Currently, when importing a database from a JSON file, the process
looks at the database name from the source (the info is in the file)
and matches the datasources to that name. If no database by that name
exists, it simply fails.
With this PR, we add a database dropdown that allows the user to specify
which databases the datasources should target as the get upserted.
I want to stress that the code in this area is not in a great shape,
and that the challenge of serializing/deser the nested objects is
challenging, but that there should be a much better way to do this.
One of the improvement (out of scope for this PR) that would allow to
simplify those import/export would be to use UUIDs for
importable/exportable objects.
Another identified issue is the indirections between
`utils/import_expor_{model}.py` on top of `{Model}.import_object`. Not
addressing that here.
Next topic is the MVC stuff. Decided to stick with it for now as this is
more of a [obious missing feat:] than a rewrite.
* isort \!? 0%^$%Y$&?%$^?%0^?
* fix tests
* pre-committing to py3.6
* address dpgaspar's comments
* revert isort
* Switch from nosetest to pytest
Fix schedule tests
Collect pytest coverage
Move pytest config into pytest.ini
Move cov to the pytest.ini
* Append coverage for the 2nd run
* Add coverage to all commands
* Coverage only for tests
* Get coverage from 1 place
* Rename classes to be pytest compatible
* Test coverage for examples and tests
* Max diff to -1
* Explain how to run pytest for the whole project
* Do not append code coverage for the main run
* Do not run coverage on examples
Co-authored-by: bogdan kyryliuk <bogdankyryliuk@dropbox.com>
* feat: Add new timegrains and convert_dttm to Druid engine spec
* Add TemporalType enum and fix test case
* Remove DATETIME for athena (original spec)
* Add multiple table filters for Row Level Security
* Set ENABLE_ROW_LEVEL_SECURITY back to False (default)
* Merge DB migrations
* Drop table_id column and foreign key on PostgreSQL, MySQL, SQLite
* Support db records migration also
* Support downgrading from the new-fashioned formatted records
* Straighten up migrations
* Update migration's down_revision to comply master branch
* Implement table mutator and examples how to set date defaults
Fix tests
* Fix flaky test
Co-authored-by: bogdan kyryliuk <bogdankyryliuk@dropbox.com>
* Remove unreferenced function from views/core.py
* Remove excess constants from views/core.py
* Extract CssTemplate-related views to their own file from core.py
* Remove duplicate constant declaration and make the constant less racist
* Move free-floating functions in views/core.py to views/utils.py
* Move AccessRequestsModelView out of views/core.py into its own module
* Move health checks and KV ModelView out of core.py and into their own modules
* Move R model view to its own module
* Move after-request header setting to views/base.py from views/core.py
* black
* mypy
* isort
* Fix reference to imported app
* pylint
* Fix some imports
* Add some missing view imports
* Fix a missing import
* First draft for the slack integration
Fix slack
another typo
another typo
Fix slack
Add channels to the form
another typo
Another set of changes
Make code more transparent
Fix tests
Add logging
logging
use logger
import logging
import logging
import logging
add assert
more logging
Fix channels
Fix channels
* Address comments
* Move slack into a separate module
Co-authored-by: bogdan kyryliuk <bogdankyryliuk@dropbox.com>
* Add owners and physical/virtual status to Datasets API list endpoint
* black
* Update type definition for DatasourceKind
Co-authored-by: Ville Brofeldt <33317356+villebro@users.noreply.github.com>
* Fixin' tests and mypy
Co-authored-by: Ville Brofeldt <33317356+villebro@users.noreply.github.com>
* remove word cloud from viz.py
* Fix Run in SQL Lab
* remove deprecated python tests
* break out legacy endpoint type into function
* Break out exploreChart from exportChart and implement results type
* Fix jest tests and refactor accordingly
* lint
* Rename v1 payload function
* Add dashboard id to v1 chart data request url params
* Add support for domain sharding to v1 chart data request
* Removing the logic to add timeseries_limit_metric to the data for table viz
* Also make the change in viz_sip_38
* Fix tests
Co-authored-by: michelle_thomas <michelle.thomas@airbnb.com>
* chore: bump pyhton dependencies
* bump flask-testing
* Add note to UPDATING and bump flask-testing in requirements-dev.txt
* fix old sqlparse test case that is fixed with sqlparse==0.3.1
* Fix migration and sqlparse set test
* downgrade alembic
* Downgrade sqlalchemy-utils
* pin sqlalchemy-utils due to regression in 0.36.5
* Refine comment in setup.py
* make cachelib an explicit requirement