Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge apache 72d1011 #51

Closed
wants to merge 34 commits into from
Closed

Merge apache 72d1011 #51

wants to merge 34 commits into from

Conversation

khtruong
Copy link

Merge apache 72d1011 into lyft-master

dpgaspar and others added 30 commits July 12, 2019 08:41
* [celery] Bump celery to 4.3.0

* re-triggering CI

* re-trigger CI

* Bump redis to 3.2.1
* fix: multi deck.gl viewport frozen

add onViewportChange method to handle changes to the viewport

* fix: add max_radius to deck.gl scatter example

- causes multi deck.gl to fail to render scatter without max_radius attribute
* Add ability to override cache backend with custom module

* Tests for setup_cache

* Add custom CACHE_CONFIG documentation

* Fix linter errors and documentation link

* Fix black formatting errors
* fix: update polygon example data to work with multi deck.gl 

- both "point_radius_fixed" and "multiplier" attributes were not set during load_examples so these charts were failing when viewing as a multi deck.gl chart

* fix: unify deck.gl getLayers api to fix multi deck.gl tooltips

- various deck.gl layers implemented getLayers slightly differently which caused issues with generating default tooltips when the layers are viewed in a multi deck.gl chart

* fix: cleanup formData variable in scatter chart for consistency

* linting fix + polygon regression fix

* additional linting fixes
* Add Auto option to point radius to make it work as expected since the example using this didn't work because of this (and also as the tooltip says the auto option should be available)

* Remove trailing space

* Fix docker configurations and docker installation guide.
- Fix installation guide regarding passing enviromental variable to docker-compose.
- Add gevent installation command in Dockerfile. (Didn't add it in requirements because it's not really a requirement for the whole project)
- Add user: root:root to allow superset service to work in development mode. Since access to binded superset directory to local requires root user.
- Also add localhost to postgres and redis services to reduce unintended security risk.

* Fix docker configurations and docker installation guide.
- Fix installation guide regarding passing enviromental variable to docker-compose.
- Add gevent installation command in Dockerfile. (Didn't add it in requirements because it's not really a requirement for the whole project)
- Add user: root:root to allow superset service to work in development mode. Since access to binded superset directory to local requires root user.
- Also add localhost to postgres and redis services to reduce unintended security risk.
* Avoid removing custom sql adhoc metric when columns change

* Add tests to confirm sql metric does not get removed
* [WiP] improve load_examples

related to apache#7472, longer term we will generate the examples by exporting
them into tarball as in apache#7472. In the meantime, we need this subset of
the features:

* allowing specifying an alternate database connection for examples
* allowing a --only-metadata flag to `load_examples` to load only
  dashboard and chart definitions, no actual data is loaded

* Improve logging

* Rename data->examples

* Load only if not exist

* By default do not load, add a force flag

* fix build

* set published to true
* [sql lab] improve TableElement controls

Making TableElement (table metadata shown in left panel in SQL Lab) show
controls only on hover, and use caret to expand/collapse

* Lint
* Remove unnecessary fields from dashboard exported json

This commit makes export respect export_fields and doesn't export
unnecessary relations (like users with passwords hashes) which are
ignored during the import.

* Allow to import dashboard without position_json

In case charts were added from chart-edit page and wasn't re-ordered on
the dashboard position_json field is empty and import was failing with
error.

* Update export/import tests
It makes easier to review changes in dashboards and use git diff
* Fix missing `gevent` extra dependency in Docker setup

* Add missing ASF header
* [text] Fix test data remove slice_name

* fix review comment
… sqllab (apache#7907)

* fix(sql-lab explore):   fixed response data and header type to be aligned

* fix(sql-lab explore):   fixed test error caused by incorrect test at master

* fix(sql-lab explore):   reformatted

* fix(sql-lab explore):   removed unused import
)

1. remove duplicated entries in many-to-many relation tbl dashboard_slices
2. add unique constraint on tbl
3. update the model to include the uniqueness constraint
* [api] [database] New, migrate to new FAB API side by side

* [database] view and api module reorganization

* [style] Fix, flake8

* [test] [database] Fix, tests for new database view structure

* [style] [database] black

* [database] Fix, missing apache license

* Migrate databaasync api to the new api

* flake8

* More efficient api call

* Revert querySearch to old API, test

* dummy commit

* revert config.py commit

* Remove unused import

* Remove old API view

* Remove new API view

* Add database filter

* Add database filter

* Add database filter

* Remove comments on js

* Fix JS test

* Fix pylint

* QuerySearch new databaseasync API endpoint

* Fix, query search new api endpoint

* Reintroduce old API for smooth side by side migration

* Better naming and use common hooks for view and API

* black it

* Fix, database mixin must come first

* Fix, lint
* Allow to pass user for dashboard import cli

Dashboard import assign current user from flask context during import.
But in case of cli import there is no flask user and imported charts
don't have an owner which prevents ability to edit them.

* Reset ownership on dashboard import

For overriding existing charts it requires `owners` property to be set.

* Add tests for reset ownership

* Use ORM to decode dashboards json

Creating instances using ORM allows to normally work with relations

* Fix test_import_dashboard_1_slice test

Previously tests used side-effect of slices import which kept id from
json on insert into db.
smacker and others added 4 commits July 22, 2019 22:31
The bug was introduced in apache#7773

It uses filter by `cls.table_name == datasource_name`:
https://github.com/apache/incubator-superset/pull/7773/files#diff-a8dd5ec8d8decda2e3c5571d1ec0cdb6R740

But export puts `slc.datasource.name` into exported json:
https://github.com/apache/incubator-superset/pull/7773/files#diff-ceeb7eee8d573333109e0037299c9711L673

`slc.datasource.name` in case of `SqlaTable` is `"{}.{}".format(self.schema, self.table_name)`
* Create query_obj for every filter

* Deprecate is_prequery and prequeries from query_obj

* Fix tests

* Fix typos and remove redundant ; from sql

* Add typing to namedtuples and move all query str logic to one place

* Fix unit test
…apache#7912)

* Fix limit parsing bug when using limit-offset comma notation

* Use native sqlparse semantics to find limit

* black
@khtruong khtruong closed this Aug 20, 2019
@khtruong khtruong deleted the merge_apache_v2_72d1011 branch August 30, 2019 21:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet