You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2021/02/18 15:36:22 UTC
[GitHub] [superset] dpgaspar opened a new pull request #13212: refactor(api): csrf token on the new REST API
dpgaspar opened a new pull request #13212:
URL: https://github.com/apache/superset/pull/13212
### SUMMARY
Creates a new REST API endpoint to fetch the CSRF token from.
The goal is to deprecate the old API `/superset/csrf_token` in favour of this new endpoint.
Before making the old endpoint issue a deprecation log message, we need to migrate the front-end client to this new endpoint.
By using this new endpoint, it's now easier to use the new API programatically by using JWT tokens to authenticate (only available to Auth DB and Auth LDAP, yet can work with other configurations by creating a username/password on the DB)
### ADDITIONAL INFORMATION
- [ ] Has associated issue:
- [ ] Changes UI
- [ ] Requires DB Migration.
- [ ] Confirm DB Migration upgrade and downgrade tested.
- [ ] Introduces new feature or API
- [ ] Removes existing feature or API
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (fe20b2f) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `5.39%`.
> The diff coverage is `71.86%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
==========================================
+ Coverage 53.06% 58.45% +5.39%
==========================================
Files 489 468 -21
Lines 17314 15948 -1366
Branches 4482 4111 -371
==========================================
+ Hits 9187 9323 +136
+ Misses 8127 6625 -1502
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `58.45% <71.86%> (+5.39%)` | :arrow_up: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [...erset-frontend/src/SqlLab/components/ResultSet.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1Jlc3VsdFNldC50c3g=) | `4.16% <0.00%> (-0.09%)` | :arrow_down: |
| [...end/src/SqlLab/components/RunQueryActionButton.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1J1blF1ZXJ5QWN0aW9uQnV0dG9uLnRzeA==) | `52.77% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartContainer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0Q29udGFpbmVyLmpzeA==) | `100.00% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartRenderer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0UmVuZGVyZXIuanN4) | `75.67% <0.00%> (-1.04%)` | :arrow_down: |
| [...perset-frontend/src/common/components/Dropdown.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL0Ryb3Bkb3duLnRzeA==) | `50.00% <ø> (ø)` | |
| [...t-frontend/src/common/components/Tooltip/index.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL1Rvb2x0aXAvaW5kZXgudHN4) | `100.00% <ø> (ø)` | |
| [...perset-frontend/src/components/AlteredSliceTag.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQWx0ZXJlZFNsaWNlVGFnLmpzeA==) | `92.00% <ø> (ø)` | |
| [superset-frontend/src/components/CachedLabel.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2FjaGVkTGFiZWwuanN4) | `42.10% <ø> (ø)` | |
| [...ontend/src/components/CertifiedIconWithTooltip.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2VydGlmaWVkSWNvbldpdGhUb29sdGlwLnRzeA==) | `0.00% <ø> (ø)` | |
| [...perset-frontend/src/components/CopyToClipboard.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ29weVRvQ2xpcGJvYXJkLmpzeA==) | `57.14% <0.00%> (ø)` | |
| ... and [172 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...fe20b2f](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (062a00e) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `5.40%`.
> The diff coverage is `71.86%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
==========================================
+ Coverage 53.06% 58.46% +5.40%
==========================================
Files 489 468 -21
Lines 17314 15948 -1366
Branches 4482 4111 -371
==========================================
+ Hits 9187 9324 +137
+ Misses 8127 6624 -1503
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `58.46% <71.86%> (+5.40%)` | :arrow_up: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [...erset-frontend/src/SqlLab/components/ResultSet.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1Jlc3VsdFNldC50c3g=) | `4.16% <0.00%> (-0.09%)` | :arrow_down: |
| [...end/src/SqlLab/components/RunQueryActionButton.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1J1blF1ZXJ5QWN0aW9uQnV0dG9uLnRzeA==) | `52.77% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartContainer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0Q29udGFpbmVyLmpzeA==) | `100.00% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartRenderer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0UmVuZGVyZXIuanN4) | `75.67% <0.00%> (-1.04%)` | :arrow_down: |
| [...perset-frontend/src/common/components/Dropdown.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL0Ryb3Bkb3duLnRzeA==) | `50.00% <ø> (ø)` | |
| [...t-frontend/src/common/components/Tooltip/index.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL1Rvb2x0aXAvaW5kZXgudHN4) | `100.00% <ø> (ø)` | |
| [...perset-frontend/src/components/AlteredSliceTag.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQWx0ZXJlZFNsaWNlVGFnLmpzeA==) | `92.00% <ø> (ø)` | |
| [superset-frontend/src/components/CachedLabel.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2FjaGVkTGFiZWwuanN4) | `42.10% <ø> (ø)` | |
| [...ontend/src/components/CertifiedIconWithTooltip.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2VydGlmaWVkSWNvbldpdGhUb29sdGlwLnRzeA==) | `0.00% <ø> (ø)` | |
| [...perset-frontend/src/components/CopyToClipboard.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ29weVRvQ2xpcGJvYXJkLmpzeA==) | `57.14% <0.00%> (ø)` | |
| ... and [173 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...062a00e](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] dpgaspar commented on a change in pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
dpgaspar commented on a change in pull request #13212:
URL: https://github.com/apache/superset/pull/13212#discussion_r580329790
##########
File path: superset/security/api.py
##########
@@ -0,0 +1,62 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+import logging
+
+from flask import Response
+from flask_appbuilder import expose
+from flask_appbuilder.api import BaseApi, safe
+from flask_appbuilder.security.decorators import permission_name, protect
+from flask_wtf.csrf import generate_csrf
+
+from superset.extensions import event_logger
+
+logger = logging.getLogger(__name__)
+
+
+class SecurityRestApi(BaseApi):
+ resource_name = "security"
+ allow_browser_login = True
+ openapi_spec_tag = "Security"
+
+ @expose("/csrf_token/", methods=["GET"])
+ @event_logger.log_this
+ @protect()
+ @safe
+ @permission_name("read")
Review comment:
@willbarrett Actually this led to a small refactor on tests. IMO having a public role like `Gamma` by default on all tests was dangerous, and by disabling it surfaced a bunch of tests that were not authenticated or handling anonymous users on a not 100% correct way.
Now setting the public role like `Gamma` is a fixture, so it's easy to use when needed
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (fa7b3bd) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `5.39%`.
> The diff coverage is `71.86%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
==========================================
+ Coverage 53.06% 58.45% +5.39%
==========================================
Files 489 468 -21
Lines 17314 15948 -1366
Branches 4482 4111 -371
==========================================
+ Hits 9187 9323 +136
+ Misses 8127 6625 -1502
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `58.45% <71.86%> (+5.39%)` | :arrow_up: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [...erset-frontend/src/SqlLab/components/ResultSet.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1Jlc3VsdFNldC50c3g=) | `4.16% <0.00%> (-0.09%)` | :arrow_down: |
| [...end/src/SqlLab/components/RunQueryActionButton.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1J1blF1ZXJ5QWN0aW9uQnV0dG9uLnRzeA==) | `52.77% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartContainer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0Q29udGFpbmVyLmpzeA==) | `100.00% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartRenderer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0UmVuZGVyZXIuanN4) | `75.67% <0.00%> (-1.04%)` | :arrow_down: |
| [...perset-frontend/src/common/components/Dropdown.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL0Ryb3Bkb3duLnRzeA==) | `50.00% <ø> (ø)` | |
| [...t-frontend/src/common/components/Tooltip/index.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL1Rvb2x0aXAvaW5kZXgudHN4) | `100.00% <ø> (ø)` | |
| [...perset-frontend/src/components/AlteredSliceTag.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQWx0ZXJlZFNsaWNlVGFnLmpzeA==) | `92.00% <ø> (ø)` | |
| [superset-frontend/src/components/CachedLabel.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2FjaGVkTGFiZWwuanN4) | `42.10% <ø> (ø)` | |
| [...ontend/src/components/CertifiedIconWithTooltip.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2VydGlmaWVkSWNvbldpdGhUb29sdGlwLnRzeA==) | `0.00% <ø> (ø)` | |
| [...perset-frontend/src/components/CopyToClipboard.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ29weVRvQ2xpcGJvYXJkLmpzeA==) | `57.14% <0.00%> (ø)` | |
| ... and [172 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...ebbac6a](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] villebro commented on a change in pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
villebro commented on a change in pull request #13212:
URL: https://github.com/apache/superset/pull/13212#discussion_r580365505
##########
File path: tests/fixtures/public_role.py
##########
@@ -0,0 +1,44 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+import pytest
+
+from superset.extensions import db, security_manager
+from tests.test_app import app
+
+
+@pytest.fixture()
+def public_role_like_gamma():
+ with app.app_context():
+ app.config["PUBLIC_ROLE_LIKE"] = "Gamma"
+ security_manager.sync_role_definitions()
+
+ yield
+
+ security_manager.get_public_role().permissions = []
+ db.session.commit()
+
+
+@pytest.fixture()
+def public_role_like_test_role():
+ with app.app_context():
+ app.config["PUBLIC_ROLE_LIKE"] = "TestRole"
+ security_manager.sync_role_definitions()
+
+ yield
+
+ security_manager.get_public_role().permissions = []
+ db.session.commit()
Review comment:
Just thinking out loud, but It could be nice to add an `assume_public_role_like(role: str)` that `public_role_like_gamma` and `public_role_like_test_role` could wrap (might come in handy later if someone wants to reuse this for some other role).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io commented on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io commented on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (b6d7c10) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `11.04%`.
> The diff coverage is `62.99%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
===========================================
+ Coverage 53.06% 64.10% +11.04%
===========================================
Files 489 961 +472
Lines 17314 44984 +27670
Branches 4482 4088 -394
===========================================
+ Hits 9187 28837 +19650
- Misses 8127 16147 +8020
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `58.42% <68.22%> (+5.36%)` | :arrow_up: |
| python | `67.21% <56.54%> (?)` | |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [...erset-frontend/src/SqlLab/components/ResultSet.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1Jlc3VsdFNldC50c3g=) | `4.16% <0.00%> (-0.09%)` | :arrow_down: |
| [...end/src/SqlLab/components/RunQueryActionButton.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1J1blF1ZXJ5QWN0aW9uQnV0dG9uLnRzeA==) | `52.77% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartContainer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0Q29udGFpbmVyLmpzeA==) | `100.00% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartRenderer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0UmVuZGVyZXIuanN4) | `75.67% <0.00%> (-1.04%)` | :arrow_down: |
| [...perset-frontend/src/common/components/Dropdown.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL0Ryb3Bkb3duLnRzeA==) | `50.00% <ø> (ø)` | |
| [...t-frontend/src/common/components/Tooltip/index.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL1Rvb2x0aXAvaW5kZXgudHN4) | `100.00% <ø> (ø)` | |
| [...perset-frontend/src/components/AlteredSliceTag.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQWx0ZXJlZFNsaWNlVGFnLmpzeA==) | `92.00% <ø> (ø)` | |
| [superset-frontend/src/components/CachedLabel.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2FjaGVkTGFiZWwuanN4) | `42.10% <ø> (ø)` | |
| [...ontend/src/components/CertifiedIconWithTooltip.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2VydGlmaWVkSWNvbldpdGhUb29sdGlwLnRzeA==) | `0.00% <ø> (ø)` | |
| [...perset-frontend/src/components/CopyToClipboard.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ29weVRvQ2xpcGJvYXJkLmpzeA==) | `57.14% <0.00%> (ø)` | |
| ... and [664 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...15859e8](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] dpgaspar commented on a change in pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
dpgaspar commented on a change in pull request #13212:
URL: https://github.com/apache/superset/pull/13212#discussion_r579165035
##########
File path: superset/security/api.py
##########
@@ -0,0 +1,62 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+import logging
+
+from flask import Response
+from flask_appbuilder import expose
+from flask_appbuilder.api import BaseApi, safe
+from flask_appbuilder.security.decorators import permission_name, protect
+from flask_wtf.csrf import generate_csrf
+
+from superset.extensions import event_logger
+
+logger = logging.getLogger(__name__)
+
+
+class SecurityRestApi(BaseApi):
+ resource_name = "security"
+ allow_browser_login = True
+ openapi_spec_tag = "Security"
+
+ @expose("/csrf_token/", methods=["GET"])
+ @event_logger.log_this
+ @protect()
+ @safe
+ @permission_name("read")
Review comment:
They get automatically added on `superset init` to all roles
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] dpgaspar commented on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
dpgaspar commented on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781554825
> LGTM!
> we should also add the proper documentation on how to leverage that new API to manage /V1 API calls from an external non-frontend application
Yep, and we have some additional cool plans also
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (2e03562) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `18.21%`.
> The diff coverage is `76.09%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
===========================================
+ Coverage 53.06% 71.28% +18.21%
===========================================
Files 489 768 +279
Lines 17314 40259 +22945
Branches 4482 4116 -366
===========================================
+ Hits 9187 28697 +19510
- Misses 8127 11562 +3435
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `58.08% <71.86%> (+5.02%)` | :arrow_up: |
| python | `79.94% <82.88%> (?)` | |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [...erset-frontend/src/SqlLab/components/ResultSet.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1Jlc3VsdFNldC50c3g=) | `4.16% <0.00%> (-0.09%)` | :arrow_down: |
| [...end/src/SqlLab/components/RunQueryActionButton.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1J1blF1ZXJ5QWN0aW9uQnV0dG9uLnRzeA==) | `52.77% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartContainer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0Q29udGFpbmVyLmpzeA==) | `100.00% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartRenderer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0UmVuZGVyZXIuanN4) | `75.67% <0.00%> (-1.04%)` | :arrow_down: |
| [...perset-frontend/src/common/components/Dropdown.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL0Ryb3Bkb3duLnRzeA==) | `50.00% <ø> (ø)` | |
| [...t-frontend/src/common/components/Tooltip/index.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL1Rvb2x0aXAvaW5kZXgudHN4) | `100.00% <ø> (ø)` | |
| [...perset-frontend/src/components/AlteredSliceTag.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQWx0ZXJlZFNsaWNlVGFnLmpzeA==) | `92.00% <ø> (ø)` | |
| [superset-frontend/src/components/CachedLabel.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2FjaGVkTGFiZWwuanN4) | `42.10% <ø> (ø)` | |
| [...ontend/src/components/CertifiedIconWithTooltip.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2VydGlmaWVkSWNvbldpdGhUb29sdGlwLnRzeA==) | `0.00% <ø> (ø)` | |
| [...perset-frontend/src/components/CopyToClipboard.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ29weVRvQ2xpcGJvYXJkLmpzeA==) | `57.14% <0.00%> (ø)` | |
| ... and [515 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...dc51d99](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (2e03562) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `18.37%`.
> The diff coverage is `76.09%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
===========================================
+ Coverage 53.06% 71.43% +18.37%
===========================================
Files 489 768 +279
Lines 17314 40259 +22945
Branches 4482 4116 -366
===========================================
+ Hits 9187 28761 +19574
- Misses 8127 11498 +3371
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `58.48% <71.86%> (+5.42%)` | :arrow_up: |
| python | `79.94% <82.88%> (?)` | |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [...erset-frontend/src/SqlLab/components/ResultSet.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1Jlc3VsdFNldC50c3g=) | `4.16% <0.00%> (-0.09%)` | :arrow_down: |
| [...end/src/SqlLab/components/RunQueryActionButton.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1J1blF1ZXJ5QWN0aW9uQnV0dG9uLnRzeA==) | `52.77% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartContainer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0Q29udGFpbmVyLmpzeA==) | `100.00% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartRenderer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0UmVuZGVyZXIuanN4) | `75.67% <0.00%> (-1.04%)` | :arrow_down: |
| [...perset-frontend/src/common/components/Dropdown.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL0Ryb3Bkb3duLnRzeA==) | `50.00% <ø> (ø)` | |
| [...t-frontend/src/common/components/Tooltip/index.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL1Rvb2x0aXAvaW5kZXgudHN4) | `100.00% <ø> (ø)` | |
| [...perset-frontend/src/components/AlteredSliceTag.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQWx0ZXJlZFNsaWNlVGFnLmpzeA==) | `92.00% <ø> (ø)` | |
| [superset-frontend/src/components/CachedLabel.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2FjaGVkTGFiZWwuanN4) | `42.10% <ø> (ø)` | |
| [...ontend/src/components/CertifiedIconWithTooltip.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2VydGlmaWVkSWNvbldpdGhUb29sdGlwLnRzeA==) | `0.00% <ø> (ø)` | |
| [...perset-frontend/src/components/CopyToClipboard.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ29weVRvQ2xpcGJvYXJkLmpzeA==) | `57.14% <0.00%> (ø)` | |
| ... and [510 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...dc51d99](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (ebbac6a) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `5.39%`.
> The diff coverage is `71.86%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
==========================================
+ Coverage 53.06% 58.45% +5.39%
==========================================
Files 489 468 -21
Lines 17314 15948 -1366
Branches 4482 4111 -371
==========================================
+ Hits 9187 9323 +136
+ Misses 8127 6625 -1502
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `58.45% <71.86%> (+5.39%)` | :arrow_up: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [...erset-frontend/src/SqlLab/components/ResultSet.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1Jlc3VsdFNldC50c3g=) | `4.16% <0.00%> (-0.09%)` | :arrow_down: |
| [...end/src/SqlLab/components/RunQueryActionButton.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1J1blF1ZXJ5QWN0aW9uQnV0dG9uLnRzeA==) | `52.77% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartContainer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0Q29udGFpbmVyLmpzeA==) | `100.00% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartRenderer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0UmVuZGVyZXIuanN4) | `75.67% <0.00%> (-1.04%)` | :arrow_down: |
| [...perset-frontend/src/common/components/Dropdown.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL0Ryb3Bkb3duLnRzeA==) | `50.00% <ø> (ø)` | |
| [...t-frontend/src/common/components/Tooltip/index.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL1Rvb2x0aXAvaW5kZXgudHN4) | `100.00% <ø> (ø)` | |
| [...perset-frontend/src/components/AlteredSliceTag.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQWx0ZXJlZFNsaWNlVGFnLmpzeA==) | `92.00% <ø> (ø)` | |
| [superset-frontend/src/components/CachedLabel.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2FjaGVkTGFiZWwuanN4) | `42.10% <ø> (ø)` | |
| [...ontend/src/components/CertifiedIconWithTooltip.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2VydGlmaWVkSWNvbldpdGhUb29sdGlwLnRzeA==) | `0.00% <ø> (ø)` | |
| [...perset-frontend/src/components/CopyToClipboard.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ29weVRvQ2xpcGJvYXJkLmpzeA==) | `57.14% <0.00%> (ø)` | |
| ... and [172 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...ebbac6a](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] dpgaspar commented on a change in pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
dpgaspar commented on a change in pull request #13212:
URL: https://github.com/apache/superset/pull/13212#discussion_r579679720
##########
File path: superset/security/api.py
##########
@@ -0,0 +1,62 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+import logging
+
+from flask import Response
+from flask_appbuilder import expose
+from flask_appbuilder.api import BaseApi, safe
+from flask_appbuilder.security.decorators import permission_name, protect
+from flask_wtf.csrf import generate_csrf
+
+from superset.extensions import event_logger
+
+logger = logging.getLogger(__name__)
+
+
+class SecurityRestApi(BaseApi):
+ resource_name = "security"
+ allow_browser_login = True
+ openapi_spec_tag = "Security"
+
+ @expose("/csrf_token/", methods=["GET"])
+ @event_logger.log_this
+ @protect()
+ @safe
+ @permission_name("read")
Review comment:
paranoya is wellcome on security related matters :)
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] dpgaspar merged pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
dpgaspar merged pull request #13212:
URL: https://github.com/apache/superset/pull/13212
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] willbarrett commented on a change in pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
willbarrett commented on a change in pull request #13212:
URL: https://github.com/apache/superset/pull/13212#discussion_r578776354
##########
File path: superset/security/api.py
##########
@@ -0,0 +1,62 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+import logging
+
+from flask import Response
+from flask_appbuilder import expose
+from flask_appbuilder.api import BaseApi, safe
+from flask_appbuilder.security.decorators import permission_name, protect
+from flask_wtf.csrf import generate_csrf
+
+from superset.extensions import event_logger
+
+logger = logging.getLogger(__name__)
+
+
+class SecurityRestApi(BaseApi):
+ resource_name = "security"
+ allow_browser_login = True
+ openapi_spec_tag = "Security"
+
+ @expose("/csrf_token/", methods=["GET"])
+ @event_logger.log_this
+ @protect()
+ @safe
+ @permission_name("read")
Review comment:
Do we need to add this new permission in FAB to existing roles?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] dpgaspar commented on a change in pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
dpgaspar commented on a change in pull request #13212:
URL: https://github.com/apache/superset/pull/13212#discussion_r579679720
##########
File path: superset/security/api.py
##########
@@ -0,0 +1,62 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+import logging
+
+from flask import Response
+from flask_appbuilder import expose
+from flask_appbuilder.api import BaseApi, safe
+from flask_appbuilder.security.decorators import permission_name, protect
+from flask_wtf.csrf import generate_csrf
+
+from superset.extensions import event_logger
+
+logger = logging.getLogger(__name__)
+
+
+class SecurityRestApi(BaseApi):
+ resource_name = "security"
+ allow_browser_login = True
+ openapi_spec_tag = "Security"
+
+ @expose("/csrf_token/", methods=["GET"])
+ @event_logger.log_this
+ @protect()
+ @safe
+ @permission_name("read")
Review comment:
paranoya is wellcome on security related matters
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (6a03d32) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `5.39%`.
> The diff coverage is `71.86%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
==========================================
+ Coverage 53.06% 58.45% +5.39%
==========================================
Files 489 468 -21
Lines 17314 15948 -1366
Branches 4482 4111 -371
==========================================
+ Hits 9187 9323 +136
+ Misses 8127 6625 -1502
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `58.45% <71.86%> (+5.39%)` | :arrow_up: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [...erset-frontend/src/SqlLab/components/ResultSet.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1Jlc3VsdFNldC50c3g=) | `4.16% <0.00%> (-0.09%)` | :arrow_down: |
| [...end/src/SqlLab/components/RunQueryActionButton.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1J1blF1ZXJ5QWN0aW9uQnV0dG9uLnRzeA==) | `52.77% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartContainer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0Q29udGFpbmVyLmpzeA==) | `100.00% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartRenderer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0UmVuZGVyZXIuanN4) | `75.67% <0.00%> (-1.04%)` | :arrow_down: |
| [...perset-frontend/src/common/components/Dropdown.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL0Ryb3Bkb3duLnRzeA==) | `50.00% <ø> (ø)` | |
| [...t-frontend/src/common/components/Tooltip/index.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL1Rvb2x0aXAvaW5kZXgudHN4) | `100.00% <ø> (ø)` | |
| [...perset-frontend/src/components/AlteredSliceTag.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQWx0ZXJlZFNsaWNlVGFnLmpzeA==) | `92.00% <ø> (ø)` | |
| [superset-frontend/src/components/CachedLabel.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2FjaGVkTGFiZWwuanN4) | `42.10% <ø> (ø)` | |
| [...ontend/src/components/CertifiedIconWithTooltip.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2VydGlmaWVkSWNvbldpdGhUb29sdGlwLnRzeA==) | `0.00% <ø> (ø)` | |
| [...perset-frontend/src/components/CopyToClipboard.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ29weVRvQ2xpcGJvYXJkLmpzeA==) | `57.14% <0.00%> (ø)` | |
| ... and [172 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...fe20b2f](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] willbarrett commented on a change in pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
willbarrett commented on a change in pull request #13212:
URL: https://github.com/apache/superset/pull/13212#discussion_r579344781
##########
File path: superset/security/api.py
##########
@@ -0,0 +1,62 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+import logging
+
+from flask import Response
+from flask_appbuilder import expose
+from flask_appbuilder.api import BaseApi, safe
+from flask_appbuilder.security.decorators import permission_name, protect
+from flask_wtf.csrf import generate_csrf
+
+from superset.extensions import event_logger
+
+logger = logging.getLogger(__name__)
+
+
+class SecurityRestApi(BaseApi):
+ resource_name = "security"
+ allow_browser_login = True
+ openapi_spec_tag = "Security"
+
+ @expose("/csrf_token/", methods=["GET"])
+ @event_logger.log_this
+ @protect()
+ @safe
+ @permission_name("read")
Review comment:
You could add a test to make sure a CSRF token isn't issued when the user is not logged in - that would be my recommended way forward there. Call me paranoid, it's just that this endpoint is part of the security story for Superset.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (32d85c8) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `5.40%`.
> The diff coverage is `71.86%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
==========================================
+ Coverage 53.06% 58.46% +5.40%
==========================================
Files 489 468 -21
Lines 17314 15948 -1366
Branches 4482 4111 -371
==========================================
+ Hits 9187 9324 +137
+ Misses 8127 6624 -1503
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `58.46% <71.86%> (+5.40%)` | :arrow_up: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [...erset-frontend/src/SqlLab/components/ResultSet.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1Jlc3VsdFNldC50c3g=) | `4.16% <0.00%> (-0.09%)` | :arrow_down: |
| [...end/src/SqlLab/components/RunQueryActionButton.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1J1blF1ZXJ5QWN0aW9uQnV0dG9uLnRzeA==) | `52.77% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartContainer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0Q29udGFpbmVyLmpzeA==) | `100.00% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartRenderer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0UmVuZGVyZXIuanN4) | `75.67% <0.00%> (-1.04%)` | :arrow_down: |
| [...perset-frontend/src/common/components/Dropdown.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL0Ryb3Bkb3duLnRzeA==) | `50.00% <ø> (ø)` | |
| [...t-frontend/src/common/components/Tooltip/index.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL1Rvb2x0aXAvaW5kZXgudHN4) | `100.00% <ø> (ø)` | |
| [...perset-frontend/src/components/AlteredSliceTag.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQWx0ZXJlZFNsaWNlVGFnLmpzeA==) | `92.00% <ø> (ø)` | |
| [superset-frontend/src/components/CachedLabel.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2FjaGVkTGFiZWwuanN4) | `42.10% <ø> (ø)` | |
| [...ontend/src/components/CertifiedIconWithTooltip.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2VydGlmaWVkSWNvbldpdGhUb29sdGlwLnRzeA==) | `0.00% <ø> (ø)` | |
| [...perset-frontend/src/components/CopyToClipboard.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ29weVRvQ2xpcGJvYXJkLmpzeA==) | `57.14% <0.00%> (ø)` | |
| ... and [173 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...6a03d32](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] dpgaspar commented on a change in pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
dpgaspar commented on a change in pull request #13212:
URL: https://github.com/apache/superset/pull/13212#discussion_r579164808
##########
File path: tests/security/api_tests.py
##########
@@ -0,0 +1,37 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+# isort:skip_file
+# pylint: disable=too-many-public-methods, no-self-use, invalid-name, too-many-arguments
+"""Unit tests for Superset"""
+import json
+from tests.base_tests import SupersetTestCase
+from flask_wtf.csrf import generate_csrf
+
+
+class TestSecurityApi(SupersetTestCase):
+ resource_name = "security"
+
+ def test_get_dashboard(self):
Review comment:
Updated the test name. I can add a test for unauthorized, but this permission is given to all roles, so to add a test I need to create a user with a custom test role and it sort of feels like we are testing FAB then. Do you think it's worth it?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (062a00e) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **decrease** coverage by `1.10%`.
> The diff coverage is `53.46%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
==========================================
- Coverage 53.06% 51.95% -1.11%
==========================================
Files 489 466 -23
Lines 17314 15898 -1416
Branches 4482 4087 -395
==========================================
- Hits 9187 8260 -927
+ Misses 8127 7638 -489
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `51.95% <53.46%> (-1.11%)` | :arrow_down: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [...erset-frontend/src/SqlLab/components/ResultSet.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1Jlc3VsdFNldC50c3g=) | `4.16% <0.00%> (-0.09%)` | :arrow_down: |
| [...end/src/SqlLab/components/RunQueryActionButton.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1J1blF1ZXJ5QWN0aW9uQnV0dG9uLnRzeA==) | `52.77% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartContainer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0Q29udGFpbmVyLmpzeA==) | `100.00% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartRenderer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0UmVuZGVyZXIuanN4) | `75.67% <0.00%> (-1.04%)` | :arrow_down: |
| [...perset-frontend/src/common/components/Dropdown.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL0Ryb3Bkb3duLnRzeA==) | `50.00% <ø> (ø)` | |
| [...t-frontend/src/common/components/Tooltip/index.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL1Rvb2x0aXAvaW5kZXgudHN4) | `100.00% <ø> (ø)` | |
| [...perset-frontend/src/components/AlteredSliceTag.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQWx0ZXJlZFNsaWNlVGFnLmpzeA==) | `92.00% <ø> (ø)` | |
| [superset-frontend/src/components/CachedLabel.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2FjaGVkTGFiZWwuanN4) | `42.10% <ø> (ø)` | |
| [...ontend/src/components/CertifiedIconWithTooltip.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2VydGlmaWVkSWNvbldpdGhUb29sdGlwLnRzeA==) | `0.00% <ø> (ø)` | |
| [...perset-frontend/src/components/CopyToClipboard.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ29weVRvQ2xpcGJvYXJkLmpzeA==) | `57.14% <0.00%> (ø)` | |
| ... and [247 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...062a00e](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (2e03562) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `26.88%`.
> The diff coverage is `82.88%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
===========================================
+ Coverage 53.06% 79.94% +26.88%
===========================================
Files 489 299 -190
Lines 17314 24297 +6983
Branches 4482 0 -4482
===========================================
+ Hits 9187 19425 +10238
+ Misses 8127 4872 -3255
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `?` | |
| python | `79.94% <82.88%> (?)` | |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [superset/constants.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvY29uc3RhbnRzLnB5) | `100.00% <ø> (ø)` | |
| [superset/examples/birth\_names.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZXhhbXBsZXMvYmlydGhfbmFtZXMucHk=) | `73.19% <ø> (ø)` | |
| [superset/connectors/sqla/views.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvY29ubmVjdG9ycy9zcWxhL3ZpZXdzLnB5) | `62.43% <4.34%> (ø)` | |
| [superset/views/datasource.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdmlld3MvZGF0YXNvdXJjZS5weQ==) | `88.70% <16.66%> (ø)` | |
| [superset/views/core.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdmlld3MvY29yZS5weQ==) | `71.74% <66.66%> (ø)` | |
| [superset/charts/commands/exceptions.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvY2hhcnRzL2NvbW1hbmRzL2V4Y2VwdGlvbnMucHk=) | `92.85% <77.77%> (ø)` | |
| [superset/utils/core.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdXRpbHMvY29yZS5weQ==) | `88.26% <87.50%> (ø)` | |
| [superset/db\_engine\_specs/trino.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3RyaW5vLnB5) | `90.47% <90.47%> (ø)` | |
| [superset/dashboards/filters.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9maWx0ZXJzLnB5) | `96.00% <91.66%> (ø)` | |
| [superset/db\_engine\_specs/elasticsearch.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL2VsYXN0aWNzZWFyY2gucHk=) | `90.24% <94.44%> (ø)` | |
| ... and [693 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...dc51d99](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] willbarrett commented on a change in pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
willbarrett commented on a change in pull request #13212:
URL: https://github.com/apache/superset/pull/13212#discussion_r578776134
##########
File path: tests/security/api_tests.py
##########
@@ -0,0 +1,37 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+# isort:skip_file
+# pylint: disable=too-many-public-methods, no-self-use, invalid-name, too-many-arguments
+"""Unit tests for Superset"""
+import json
+from tests.base_tests import SupersetTestCase
+from flask_wtf.csrf import generate_csrf
+
+
+class TestSecurityApi(SupersetTestCase):
+ resource_name = "security"
+
+ def test_get_dashboard(self):
Review comment:
nit: test name
It might be good to add a test for the failure case where the user is not authorized.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (2e03562) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `26.86%`.
> The diff coverage is `82.88%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
===========================================
+ Coverage 53.06% 79.92% +26.86%
===========================================
Files 489 299 -190
Lines 17314 24269 +6955
Branches 4482 0 -4482
===========================================
+ Hits 9187 19398 +10211
+ Misses 8127 4871 -3256
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `?` | |
| python | `79.92% <82.88%> (?)` | |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [superset/constants.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvY29uc3RhbnRzLnB5) | `100.00% <ø> (ø)` | |
| [superset/examples/birth\_names.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZXhhbXBsZXMvYmlydGhfbmFtZXMucHk=) | `73.19% <ø> (ø)` | |
| [superset/connectors/sqla/views.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvY29ubmVjdG9ycy9zcWxhL3ZpZXdzLnB5) | `62.74% <4.34%> (ø)` | |
| [superset/views/datasource.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdmlld3MvZGF0YXNvdXJjZS5weQ==) | `88.70% <16.66%> (ø)` | |
| [superset/views/core.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdmlld3MvY29yZS5weQ==) | `71.74% <66.66%> (ø)` | |
| [superset/charts/commands/exceptions.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvY2hhcnRzL2NvbW1hbmRzL2V4Y2VwdGlvbnMucHk=) | `92.85% <77.77%> (ø)` | |
| [superset/utils/core.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdXRpbHMvY29yZS5weQ==) | `88.26% <87.50%> (ø)` | |
| [superset/db\_engine\_specs/trino.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3RyaW5vLnB5) | `90.47% <90.47%> (ø)` | |
| [superset/dashboards/filters.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9maWx0ZXJzLnB5) | `96.00% <91.66%> (ø)` | |
| [superset/db\_engine\_specs/elasticsearch.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL2VsYXN0aWNzZWFyY2gucHk=) | `90.24% <94.44%> (ø)` | |
| ... and [693 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...dc51d99](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (9210dac) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `26.88%`.
> The diff coverage is `82.88%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
===========================================
+ Coverage 53.06% 79.94% +26.88%
===========================================
Files 489 299 -190
Lines 17314 24297 +6983
Branches 4482 0 -4482
===========================================
+ Hits 9187 19425 +10238
+ Misses 8127 4872 -3255
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `?` | |
| python | `79.94% <82.88%> (?)` | |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [superset/constants.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvY29uc3RhbnRzLnB5) | `100.00% <ø> (ø)` | |
| [superset/examples/birth\_names.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZXhhbXBsZXMvYmlydGhfbmFtZXMucHk=) | `73.19% <ø> (ø)` | |
| [superset/connectors/sqla/views.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvY29ubmVjdG9ycy9zcWxhL3ZpZXdzLnB5) | `62.43% <4.34%> (ø)` | |
| [superset/views/datasource.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdmlld3MvZGF0YXNvdXJjZS5weQ==) | `88.70% <16.66%> (ø)` | |
| [superset/views/core.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdmlld3MvY29yZS5weQ==) | `71.74% <66.66%> (ø)` | |
| [superset/charts/commands/exceptions.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvY2hhcnRzL2NvbW1hbmRzL2V4Y2VwdGlvbnMucHk=) | `92.85% <77.77%> (ø)` | |
| [superset/utils/core.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdXRpbHMvY29yZS5weQ==) | `88.26% <87.50%> (ø)` | |
| [superset/db\_engine\_specs/trino.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3RyaW5vLnB5) | `90.47% <90.47%> (ø)` | |
| [superset/dashboards/filters.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9maWx0ZXJzLnB5) | `96.00% <91.66%> (ø)` | |
| [superset/db\_engine\_specs/elasticsearch.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL2VsYXN0aWNzZWFyY2gucHk=) | `90.24% <94.44%> (ø)` | |
| ... and [693 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...9210dac](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (d136e59) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `27.12%`.
> The diff coverage is `80.66%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
===========================================
+ Coverage 53.06% 80.18% +27.12%
===========================================
Files 489 299 -190
Lines 17314 24212 +6898
Branches 4482 0 -4482
===========================================
+ Hits 9187 19414 +10227
+ Misses 8127 4798 -3329
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `?` | |
| python | `80.18% <80.66%> (?)` | |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [superset/constants.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvY29uc3RhbnRzLnB5) | `100.00% <ø> (ø)` | |
| [superset/examples/birth\_names.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZXhhbXBsZXMvYmlydGhfbmFtZXMucHk=) | `73.19% <ø> (ø)` | |
| [superset/connectors/sqla/views.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvY29ubmVjdG9ycy9zcWxhL3ZpZXdzLnB5) | `62.43% <4.34%> (ø)` | |
| [superset/views/datasource.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdmlld3MvZGF0YXNvdXJjZS5weQ==) | `88.70% <16.66%> (ø)` | |
| [superset/viz.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdml6LnB5) | `58.61% <27.27%> (ø)` | |
| [superset/views/core.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdmlld3MvY29yZS5weQ==) | `72.91% <71.42%> (ø)` | |
| [superset/charts/commands/exceptions.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvY2hhcnRzL2NvbW1hbmRzL2V4Y2VwdGlvbnMucHk=) | `92.85% <77.77%> (ø)` | |
| [superset/utils/core.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvdXRpbHMvY29yZS5weQ==) | `88.26% <87.50%> (ø)` | |
| [superset/db\_engine\_specs/trino.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGJfZW5naW5lX3NwZWNzL3RyaW5vLnB5) | `90.47% <90.47%> (ø)` | |
| [superset/dashboards/filters.py](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQvZGFzaGJvYXJkcy9maWx0ZXJzLnB5) | `96.00% <91.66%> (ø)` | |
| ... and [693 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...d136e59](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (062a00e) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `5.00%`.
> The diff coverage is `71.86%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
==========================================
+ Coverage 53.06% 58.06% +5.00%
==========================================
Files 489 468 -21
Lines 17314 15948 -1366
Branches 4482 4111 -371
==========================================
+ Hits 9187 9260 +73
+ Misses 8127 6688 -1439
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `58.06% <71.86%> (+5.00%)` | :arrow_up: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [...erset-frontend/src/SqlLab/components/ResultSet.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1Jlc3VsdFNldC50c3g=) | `4.16% <0.00%> (-0.09%)` | :arrow_down: |
| [...end/src/SqlLab/components/RunQueryActionButton.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1J1blF1ZXJ5QWN0aW9uQnV0dG9uLnRzeA==) | `52.77% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartContainer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0Q29udGFpbmVyLmpzeA==) | `100.00% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartRenderer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0UmVuZGVyZXIuanN4) | `75.67% <0.00%> (-1.04%)` | :arrow_down: |
| [...perset-frontend/src/common/components/Dropdown.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL0Ryb3Bkb3duLnRzeA==) | `50.00% <ø> (ø)` | |
| [...t-frontend/src/common/components/Tooltip/index.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL1Rvb2x0aXAvaW5kZXgudHN4) | `100.00% <ø> (ø)` | |
| [...perset-frontend/src/components/AlteredSliceTag.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQWx0ZXJlZFNsaWNlVGFnLmpzeA==) | `92.00% <ø> (ø)` | |
| [superset-frontend/src/components/CachedLabel.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2FjaGVkTGFiZWwuanN4) | `42.10% <ø> (ø)` | |
| [...ontend/src/components/CertifiedIconWithTooltip.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2VydGlmaWVkSWNvbldpdGhUb29sdGlwLnRzeA==) | `0.00% <ø> (ø)` | |
| [...perset-frontend/src/components/CopyToClipboard.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ29weVRvQ2xpcGJvYXJkLmpzeA==) | `57.14% <0.00%> (ø)` | |
| ... and [178 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...062a00e](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (ebbac6a) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `4.99%`.
> The diff coverage is `71.86%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
==========================================
+ Coverage 53.06% 58.05% +4.99%
==========================================
Files 489 468 -21
Lines 17314 15948 -1366
Branches 4482 4111 -371
==========================================
+ Hits 9187 9259 +72
+ Misses 8127 6689 -1438
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `58.05% <71.86%> (+4.99%)` | :arrow_up: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [...erset-frontend/src/SqlLab/components/ResultSet.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1Jlc3VsdFNldC50c3g=) | `4.16% <0.00%> (-0.09%)` | :arrow_down: |
| [...end/src/SqlLab/components/RunQueryActionButton.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1J1blF1ZXJ5QWN0aW9uQnV0dG9uLnRzeA==) | `52.77% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartContainer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0Q29udGFpbmVyLmpzeA==) | `100.00% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartRenderer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0UmVuZGVyZXIuanN4) | `75.67% <0.00%> (-1.04%)` | :arrow_down: |
| [...perset-frontend/src/common/components/Dropdown.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL0Ryb3Bkb3duLnRzeA==) | `50.00% <ø> (ø)` | |
| [...t-frontend/src/common/components/Tooltip/index.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL1Rvb2x0aXAvaW5kZXgudHN4) | `100.00% <ø> (ø)` | |
| [...perset-frontend/src/components/AlteredSliceTag.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQWx0ZXJlZFNsaWNlVGFnLmpzeA==) | `92.00% <ø> (ø)` | |
| [superset-frontend/src/components/CachedLabel.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2FjaGVkTGFiZWwuanN4) | `42.10% <ø> (ø)` | |
| [...ontend/src/components/CertifiedIconWithTooltip.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2VydGlmaWVkSWNvbldpdGhUb29sdGlwLnRzeA==) | `0.00% <ø> (ø)` | |
| [...perset-frontend/src/components/CopyToClipboard.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ29weVRvQ2xpcGJvYXJkLmpzeA==) | `57.14% <0.00%> (ø)` | |
| ... and [177 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...ebbac6a](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] willbarrett commented on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
willbarrett commented on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-782443690
@dpgaspar as part of this PR, let's also add a deprecation notice on `/superset/csrf_token` for 2.0 - we can schedule the follow-up work to migrate front-end usage prior to that I believe.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] codecov-io edited a comment on pull request #13212: refactor(api): csrf token on the new REST API
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #13212:
URL: https://github.com/apache/superset/pull/13212#issuecomment-781441889
# [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=h1) Report
> Merging [#13212](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=desc) (32d85c8) into [master](https://codecov.io/gh/apache/superset/commit/2ce79823dfad61bce6196fcacd56a844f44818c0?el=desc) (2ce7982) will **increase** coverage by `5.00%`.
> The diff coverage is `71.86%`.
[](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #13212 +/- ##
==========================================
+ Coverage 53.06% 58.06% +5.00%
==========================================
Files 489 468 -21
Lines 17314 15948 -1366
Branches 4482 4111 -371
==========================================
+ Hits 9187 9260 +73
+ Misses 8127 6688 -1439
```
| Flag | Coverage Δ | |
|---|---|---|
| cypress | `58.06% <71.86%> (+5.00%)` | :arrow_up: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [...erset-frontend/src/SqlLab/components/ResultSet.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1Jlc3VsdFNldC50c3g=) | `4.16% <0.00%> (-0.09%)` | :arrow_down: |
| [...end/src/SqlLab/components/RunQueryActionButton.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1J1blF1ZXJ5QWN0aW9uQnV0dG9uLnRzeA==) | `52.77% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartContainer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0Q29udGFpbmVyLmpzeA==) | `100.00% <ø> (ø)` | |
| [superset-frontend/src/chart/ChartRenderer.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NoYXJ0L0NoYXJ0UmVuZGVyZXIuanN4) | `75.67% <0.00%> (-1.04%)` | :arrow_down: |
| [...perset-frontend/src/common/components/Dropdown.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL0Ryb3Bkb3duLnRzeA==) | `50.00% <ø> (ø)` | |
| [...t-frontend/src/common/components/Tooltip/index.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbW1vbi9jb21wb25lbnRzL1Rvb2x0aXAvaW5kZXgudHN4) | `100.00% <ø> (ø)` | |
| [...perset-frontend/src/components/AlteredSliceTag.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQWx0ZXJlZFNsaWNlVGFnLmpzeA==) | `92.00% <ø> (ø)` | |
| [superset-frontend/src/components/CachedLabel.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2FjaGVkTGFiZWwuanN4) | `42.10% <ø> (ø)` | |
| [...ontend/src/components/CertifiedIconWithTooltip.tsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ2VydGlmaWVkSWNvbldpdGhUb29sdGlwLnRzeA==) | `0.00% <ø> (ø)` | |
| [...perset-frontend/src/components/CopyToClipboard.jsx](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2NvbXBvbmVudHMvQ29weVRvQ2xpcGJvYXJkLmpzeA==) | `57.14% <0.00%> (ø)` | |
| ... and [178 more](https://codecov.io/gh/apache/superset/pull/13212/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=footer). Last update [f85497e...6a03d32](https://codecov.io/gh/apache/superset/pull/13212?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org