Commit Graph

3734 Commits

Author SHA1 Message Date
shizidushu 4e03d41f17 fix #6530 and add some other chinese translation (#6569) 2018-12-27 12:45:50 -08:00
Karri Niemelä f424af8385 json_iso_dttm_ser use for TableViz (#6563) 2018-12-27 11:38:05 -08:00
Maxime Beauchemin fe77b57581
[refactor] moving some datasource-related code to the frontend (#5769)
* [refactor] moving some datasource-related code to the frontend

* fix js tests

* fix tests

* fix test
2018-12-22 18:06:36 -08:00
Karri Niemelä eff4e6362c Adding missing slash (#6567) 2018-12-22 16:44:31 -08:00
Maxime Beauchemin d427db0a8b [SQL Lab] Allow running multiple statements (#6112)
* Allow running multiple statements from SQL Lab

* fix tests

* More tests

* merge heads

* fix heads
2018-12-22 10:28:22 -08:00
Maxime Beauchemin 6e942c9fb3
Make boto3/botocore installation optional (#6540)
* Make boto3 installation optional

* pylinting
2018-12-21 12:27:57 -08:00
Maxime Beauchemin 60ccf3eb9d [SIP-14] remove dependency on yarn in favor of npm (#6541)
* [SIP-14] remove dependency on yarn in favor of npm

Find more details here
https://github.com/apache/incubator-superset/issues/6217

* Add core-js to dev deps

* lint

* fix cypress

* break down cypress_build.sh

* fix cypress

* Use 'npm ci' in place of 'npm install'

* Bump npm req to >=6.5.0

* Enforcing  npm@'>=6.5.0'

* Using latest lts of nvm

* Make cache settings global

* remove uneeded 'npm run test' as 'npm run cover' takes care of that

* Prefix with 'time'

* Trying to upgrade babel-eslint instead of downgrading

* upgrading babel-polyfill to '@babel/polyfill'

* Moving to babel 7

* remove unused packages
2018-12-21 10:24:49 -08:00
Maxime Beauchemin 8c6ddbc842
Fix multiple db_migrations heads (#6560) 2018-12-20 22:08:52 -08:00
leakingoxide fd0338614a Make owner a m2m relation on datasources (#6544)
* Make owner a m2m relation on datasources

* Fix pylint

* Make migration work in mysql & sqlite
2018-12-20 20:35:32 -08:00
Yongjie Zhao 6a95f8070a minor, auto tune debug mode when use flask_env (#6550)
* minor, auto tune debug mode when use flask_env

* update changes
2018-12-20 20:35:06 -08:00
Maxime Beauchemin 42067e077b
[RfC] Fix URL too long (#6519)
When a URL gets too long (usually happens with controls that allow
free form text), it creates an array of bugs.
* bug when creating a short URL, because the POST request's referrer
field is too long
* a bug when saving a chart (when the modal shows up) also because of
the referrer being too long

Some work has been done in the past to mitigate this, and I'm unclear if
it's some sort of regression because of the Flask upgrade or some
browser change, or whether these bugs have always been around.

This is a request for comment on an approach that works. Let me know if
you can think of better ideas as to how to manage this.

My current solution looks for 8000+ characters URLs and shrinks them to
only `/superset/explore/?URL_IS_TOO_LONG_TO_SHARE&form_data=...` and we
only keep the formData keys for `datasource` and `viz_type`. Not super
elegant but does the trick.
2018-12-18 16:14:20 -08:00
Maxime Beauchemin 5a1ff0f09d
[cosmetic] add css no-wrap on CRUD's last modified (#6522) 2018-12-18 16:13:21 -08:00
Maxime Beauchemin 3f29a1dd70
Secure unsecured views and prevent regressions (#6553)
* Secure views and prevent regressions

* Force POST on shortner

* Fix tests
2018-12-18 11:57:13 -08:00
MukaJiTrue 926f78c21d Fix deck.gl Polygon not show (#6545)
* Fix deck.gl Polygon not show

* Replace "//" to "// "
2018-12-18 11:16:09 -08:00
dragons b06941945c fix addr_str format bug (#6551) 2018-12-18 11:03:15 -08:00
Beto Dealmeida e2b9625d84
Increase size of column `name` in table `ab_view_meu` (#6532)
* Create migration script

* Use batch operation for ALTER COLUMN
2018-12-18 10:57:45 -08:00
Beto Dealmeida 672c470e79
Pass security manager to QUERY_LOGGER (#6548)
* Pass security manager to log_query

* Fix lint
2018-12-18 10:55:58 -08:00
Antoan Milkov fe994900ec filter_values documentation fix (#5977) 2018-12-17 21:20:46 -08:00
Ville Brofeldt c4884e3c2e Remove note about snowflake-sqlalchemy stable version regression (#6398) 2018-12-17 21:20:00 -08:00
Chanakya c6263fc096 Documentation Correction to use http.server for Python3 (#6549) 2018-12-17 17:20:33 -08:00
Mars 95cdda4482 Fix string value displaying NaN (#6534) 2018-12-17 17:03:51 -08:00
Marcus 9ec3e18ecb adding in a dependency version to fix an error with Flask CLI (#6547) 2018-12-17 13:46:04 -08:00
Hugh A. Miles II e2854994ba
Add docker files to gitignore (#6507)
* add docker files to gitignore

* Update .gitignore
2018-12-16 21:24:16 -08:00
Ville Brofeldt 5bac723df4 Refactor teradata to new time_grain_functions spec (#6539)
* Refactor teradata to new time_grain_functions spec

* Add test for time_grain_functions
2018-12-16 08:53:29 -08:00
michellethomas fe0f5e968e
Avoid resetting margin to 0 (#6536)
* Avoid resetting margin to 0

* Fixing margin for pie chart
2018-12-14 14:17:45 -08:00
John Bodley 1fba6f7a17
[warm] Enforcing consistent form-data (#6531) 2018-12-14 14:00:38 +13:00
Beto Dealmeida 852c51219b Update requests version (#6510)
* Update requests version

* Run pip-compile --output-file requirements.txt
2018-12-11 22:01:06 -08:00
Kengo Seki d203886e47 Fix malformed table in docs/visualization.rst (#6409) 2018-12-11 16:49:17 -08:00
Krist Wongsuphasawat 96a0105f7a
Update contributing.md with latest local dev instructions (#6513) 2018-12-11 13:45:50 -08:00
Omkar Yadav 56aa7ac7c6 Typo: Fixed link (#6087) 2018-12-11 10:42:13 -08:00
Mahendra M 808622414c [SIP-3] Scheduled email reports for Slices / Dashboards (#5294)
* [scheduled reports] Add support for scheduled reports

* Scheduled email reports for slice and dashboard visualization
  (attachment or inline)
* Scheduled email reports for slice data (CSV attachment on inline table)
* Each schedule has a list of recipients (all of them can receive a single mail,
  or separate mails)
* All outgoing mails can have a mandatory bcc - for audit purposes.
* Each dashboard/slice can have multiple schedules.

In addition, this PR also makes a few minor improvements to the celery
infrastructure.
* Create a common celery app
* Added more celery annotations for the tasks
* Introduced celery beat
* Update docs about concurrency / pools

* [scheduled reports] - Debug mode for scheduled emails

* [scheduled reports] - Ability to send test mails

* [scheduled reports] - Test email functionality - minor improvements

* [scheduled reports] - Rebase with master. Minor fixes

* [scheduled reports] - Add warning messages

* [scheduled reports] - flake8

* [scheduled reports] - fix rebase

* [scheduled reports] - fix rebase

* [scheduled reports] - fix flake8

* [scheduled reports] Rebase in prep for merge

* Fixed alembic tree after rebase
* Updated requirements to latest version of packages (and tested)
* Removed py2 stuff

* [scheduled reports] - fix flake8

* [scheduled reports] - address review comments

* [scheduled reports] - rebase with master
2018-12-10 22:29:29 -08:00
Beto Dealmeida f366bbe735
Google spreadsheets (#5915)
* Google spreadsheets

* Fetch table metadata in SQL Lab

* Show full URL for spreadsheet

* Fix version

* Remove sqllab changes
2018-12-10 13:11:54 -08:00
michellethomas 23a2ab1077
Adding tests for time table, formatting, and annotations (#6498) 2018-12-10 12:16:11 -08:00
aboganas 96f510619c Fix Annotation (#6457) 2018-12-09 08:00:47 -08:00
Maxime Beauchemin f5a277cc72
Pypi has a 60mb package size limit, and we're over (#6493)
* removing india country map which is 12MB+
* removing src/ in general, keeping the countries folder which has geo
data
2018-12-08 23:52:47 -08:00
Maxime Beauchemin 4109e893d3
Bump pydruid to 0.5.0 (#6454) 2018-12-08 23:47:55 -08:00
Beto Dealmeida 5168c69a25
Hook for auditing queries (#6484)
* Hook for auditing queries

* Address comments

* Use __name__
2018-12-07 12:19:19 -08:00
leakingoxide eb408d71c4 Add copy to clipboard buttons in explore and sqllab (#6461)
* Add copy to clipboard buttons in explore and sqllab

* Eslint fixes

* Review changes: deconstruct props, extract function to utils, add tests
2018-12-07 10:03:33 -08:00
Conglei fc8acf27c8 [Bug Fix]Prevent re-rendering when non-instant controls change (#6483)
fix: Prevent re-rendering when non-instant controls change
2018-12-05 17:31:59 -08:00
zhaoyu89730105 fd54de7856 FixBug druidMetricModels No attribute get_perm (#6432) 2018-12-05 09:46:38 -08:00
leakingoxide 8307716d72 Add See Tableview Form button to the Datasource Editor modal (#6430)
* Add See Tableview Form button to the Datasource Editor modal

* Change the text on datasource edit button
2018-12-04 20:44:13 -08:00
Junda Yang 13f374aa9e make loading icon bigger (#6485) 2018-12-04 20:43:14 -08:00
Krist Wongsuphasawat fcec748b62
Use @superset-ui/number-format and @superset-ui/time-format for formatting. (#6470)
refactor: proxy all d3 number and time formatting calls
2018-12-04 13:24:07 -08:00
Maxime Beauchemin cc3a625a4b
Use py3's f-strings instead of s.format(**locals()) (#6448)
* Use py3's f-strings instead of s.format(**locals())

In light of the bug reported here
https://github.com/apache/incubator-superset/issues/6347, which seems
like an odd `.format()` issue in py3, I greped and replaced all
instances of `.format(**locals())` using py3's f-strings

* lint

* fix tests
2018-12-02 13:50:49 -08:00
Marek Šuppa 002518ba49 Update sqllab.rst (#6469)
* Set correct link to the Celery Project
2018-12-01 09:34:49 -08:00
Grace Guo 8e14e0bd67
allow domain sharding in frontend (#5039) 2018-11-30 10:30:04 -08:00
Krist Wongsuphasawat 20e1ac6242
Update `@superset-ui/colors` (#6464)
* Update package version and update breaking changes for color

* update color function usage

* update dependency
2018-11-30 09:50:42 -08:00
Chris Williams 5f7817a6a3
[SIP-5] Build metrics in query_object in the client (#6423)
* [SIP-5] Build metrics in query_object in the client
- Unify the metric interface (absorb the current plain string metric for built-in metric keys into the format used by adhoc metric)
- Port the logic in adhocMetric on the client and process_metrics in the backend to the new typed Metrics class
- Omit hasCustomLabel and formFromData properties from the new metric interface as their value can be inferred from label and optionName
- Expose from the Metrics class both metrics and their labels as public methods to match the all_metrics and metric_labels fields in the backend code
- Provide defaut values for filters, metrics and groupby in the backend

* addressing PR comments

* Adding a comment for metrictype values
2018-11-29 20:57:55 -08:00
michellethomas 5261d8a9fe
Fixing error when clearing big number (#6465) 2018-11-29 18:52:49 -08:00
Krist Wongsuphasawat e715cdb9ac
[READY] Update SuperChart onRenderXXX listeners (#6376)
* Revise LoadableRenderer (+3 squashed commits)
Squashed commits:
[f1614c7c] extract createLoadableRenderer into a separate function
[8689bc94] extend LoadableRenderer
[3d04ff2b] remove skipRendering

* add number of times function was called to the test
2018-11-29 11:09:08 -08:00