You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "villebro (via GitHub)" <gi...@apache.org> on 2023/11/12 03:20:25 UTC
[PR] chore: harmonize and clean up list views [superset]
villebro opened a new pull request, #25961:
URL: https://github.com/apache/superset/pull/25961
### SUMMARY
TODO
### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
<!--- Skip this if not applicable -->
### TESTING INSTRUCTIONS
<!--- Required! What steps can be taken to manually verify the changes? -->
### ADDITIONAL INFORMATION
<!--- Check any relevant boxes with "x" -->
<!--- HINT: Include "Fixes #nnn" if you are fixing an existing issue -->
- [ ] Has associated issue:
- [ ] Required feature flags:
- [ ] Changes UI
- [ ] Includes DB Migration (follow approval process in [SIP-59](https://github.com/apache/superset/issues/13351))
- [ ] Migration is atomic, supports rollback & is backwards-compatible
- [ ] Confirm DB migration upgrade and downgrade tested
- [ ] Runtime estimates and downtime expectations provided
- [ ] 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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1834359043
> These changes all look excellent to me! We don't use the "created by" field and I'd be happy to see it gone.
>
> To me it's right on the borderline of being a tiny breaking change or not, I don't feel strongly if that part is held off for 4.0 or done now. If it's easy to pull that part out for 4.0, great, if it's significant extra work then I'd just say merge it.
Thanks for the review @sfirke . I also agree that this feels like an acceptable breaking change, and could be swept under the "UX debt cleanup" rug 😛 I defer to @michael-s-molina and @eschutho for semver compliance - if you feel strongly about retaining the existing functionality then I'm happy to "disagree and commit" and add it back, but otherwise I propose doing like Sam said above.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1836961870
@villebro Ephemeral environment spinning up at http://35.89.27.16:8080. Credentials are `admin`/`admin`. Please allow several minutes for bootstrapping and startup.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "codecov[bot] (via GitHub)" <gi...@apache.org>.
codecov[bot] commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1819676659
## [Codecov](https://app.codecov.io/gh/apache/superset/pull/25961?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
All modified and coverable lines are covered by tests :white_check_mark:
> Comparison is base [(`bece2ea`)](https://app.codecov.io/gh/apache/superset/commit/bece2ea3e4b9979f3f45f63aa490f499095c7078?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) 69.05% compared to head [(`5230e39`)](https://app.codecov.io/gh/apache/superset/pull/25961?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) 58.76%.
> Report is 9 commits behind head on master.
<details><summary>Additional details and impacted files</summary>
```diff
@@ Coverage Diff @@
## master #25961 +/- ##
===========================================
- Coverage 69.05% 58.76% -10.29%
===========================================
Files 1938 1938
Lines 75837 75818 -19
Branches 8427 8412 -15
===========================================
- Hits 52367 44558 -7809
- Misses 21300 29103 +7803
+ Partials 2170 2157 -13
```
| [Flag](https://app.codecov.io/gh/apache/superset/pull/25961/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Coverage Δ | |
|---|---|---|
| [hive](https://app.codecov.io/gh/apache/superset/pull/25961/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
| [mysql](https://app.codecov.io/gh/apache/superset/pull/25961/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
| [postgres](https://app.codecov.io/gh/apache/superset/pull/25961/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
| [presto](https://app.codecov.io/gh/apache/superset/pull/25961/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `53.62% <100.00%> (-0.02%)` | :arrow_down: |
| [python](https://app.codecov.io/gh/apache/superset/pull/25961/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `61.49% <100.00%> (-21.41%)` | :arrow_down: |
| [sqlite](https://app.codecov.io/gh/apache/superset/pull/25961/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
| [unit](https://app.codecov.io/gh/apache/superset/pull/25961/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `55.73% <100.00%> (+0.03%)` | :arrow_up: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#carryforward-flags-in-the-pull-request-comment) to find out more.
</details>
[:umbrella: View full report in Codecov by Sentry](https://app.codecov.io/gh/apache/superset/pull/25961?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
:loudspeaker: Have feedback on the report? [Share it here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "kasiazjc (via GitHub)" <gi...@apache.org>.
kasiazjc commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1832467092
Thanks @villebro for cleaning it up 🙏 very much appreciated!
I have one concern about removing "created by" column. I think there is no other place (besides metadata bar in explore, but we don't have it in dashboards?) where you could see who created a dashboard or a chart + owners are not required I think. So if there are some random dashboards/charts it could be hard to find the right person to talk to about it if there is no information like this easily available. Thoughts?
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "michael-s-molina (via GitHub)" <gi...@apache.org>.
michael-s-molina commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1833873443
Thanks for working to improve consistency @villebro. Some things I noticed:
- The filter is called `Owner` but the list header is `Owners` (plural).
- Some filters use plural form and others use singular form in a inconsistent manner. I believe the nomenclature here should reflect the filter type. Singular for filters that allow only one value and plural for filters that allow multiple values.
- `Last modified` generally has the form of `15 hours ago` but in the charts list it's `2023-11-30T13:53:56.840190`
- The filter is called `Chart Type` in the charts list but in the datasets list it's called `Type`
- The filter in the tags list is called `Search` instead of `Name`
- In the database list the column is called `Name` but in the modal it's called `Display name`
> I find that it's often of very limited utility to know who created a chart/dashboard - usually you really want to know who owns it, or who modified it last (the creator can often have left the team/org, hence may no longer be relevant, especially for long lived assets).
I agree with this assessment but I'm wondering if this would constitute a breaking change according to our [Semantic Versioning](https://github.com/apache/superset/wiki/Semantic-Versioning) definition:
> What is a breaking change?
>
> Changes that removes an existing functionality, such as a chart type or ability to select favorites.
My suggestion would be to add a card to the [4.0 board](https://github.com/orgs/apache/projects/292) to remove the creator in the next major and for this PR, I would change the creator to be an avatar similar to the owners for consistency and to preserve real estate.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on code in PR #25961:
URL: https://github.com/apache/superset/pull/25961#discussion_r1399986203
##########
superset-frontend/src/components/AsyncAceEditor/index.tsx:
##########
@@ -25,6 +25,7 @@ import {
} from 'brace';
import AceEditor, { IAceEditorProps } from 'react-ace';
import { acequire } from 'ace-builds/src-noconflict/ace';
+import 'ace-builds/webpack-resolver';
Review Comment:
Without this we get a failed network request when opening up the edit modal in the CSS list view + no syntax highlighting (it's even uglier with `dev-server`):
<img width="1204" alt="image" src="https://github.com/apache/superset/assets/33317356/2060c2e7-bf6c-4105-996a-72aaeced9819">
After adding this, no more failed network request + CSS syntax highlighting works:
<img width="1206" alt="image" src="https://github.com/apache/superset/assets/33317356/8a73df2b-cece-4959-95c2-3546e03eea5d">
Adding this import was a recommendation in this thread, and seemed to be an ok fix: https://github.com/securingsincity/react-ace/issues/725
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1832454870
@villebro Ephemeral environment spinning up at http://34.221.220.71:8080. Credentials are `admin`/`admin`. Please allow several minutes for bootstrapping and startup.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1832654189
> You've renamed the dashboard `Title` column to `Name` (for consistency) and I was wondering whether this should be reflected throughout for consistency, i.e., in the modal when editing.
@john-bodley that's a great point - I did a quick sweep, and changed all the titles to "Name" in the modals in https://github.com/apache/superset/pull/25961/commits/8a56ffa6644b053fa305e7495aede7ffe8e9be42 . There's probably additional work that needs to be done, especially in the modals, but it may be a good idea to tackle those in another PR to limit the blast radius of this set of changes.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "giftig (via GitHub)" <gi...@apache.org>.
giftig commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1833405455
@villebro in my case I sometimes look for virtual datasets I've created by searching by creator. I don't think it's necessary for the list view (in fact I've only just noticed it's missing from there since "modified by" was generally the creator).
I think it'd be good to keep the ability to search by it. We encourage our users to always create virtual datasets when building charts, as we want them to use a macro we've written which enforces a date filter and prevents accidentally querying too much data. That means we have a lot of virtual datasets (added to thousands of physical ones).
Searching by owner would usually work, but users working with their teams might be assigning ownership to other people and it might get muddied. I'm somewhat speculating here as we don't have enough usage information from our users. Searching by modified would probably be misleading if someone else has since touched your dataset.
So I think I'd lean towards continuing to allow searching by original creator, but agree that it's best to consistently exclude it from list views.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on code in PR #25961:
URL: https://github.com/apache/superset/pull/25961#discussion_r1411441065
##########
superset-frontend/src/pages/SavedQueryList/index.tsx:
##########
@@ -497,28 +489,22 @@ function SavedQueryList({
),
paginate: true,
},
-
- {
- Header: t('Search'),
- id: 'label',
- key: 'search',
- input: 'search',
- operator: FilterOperator.allText,
- },
+ ...(isFeatureEnabled(FeatureFlag.TAGGING_SYSTEM) && canReadTag
+ ? [
+ {
+ Header: t('Tag'),
+ id: 'tags',
+ key: 'tags',
+ input: 'select',
+ operator: FilterOperator.savedQueryTags,
+ fetchSelects: loadTags,
+ },
+ ]
+ : []),
],
[addDangerToast],
);
- if (isFeatureEnabled(FeatureFlag.TAGGING_SYSTEM) && canReadTag) {
- filters.push({
- Header: t('Tags'),
- id: 'tags',
- key: 'tags',
- input: 'search',
- operator: FilterOperator.savedQueryTags,
- });
- }
-
Review Comment:
This was done outside the useMemo, causing the tags filter to get appended multiple times to the filter array:
<img width="1163" alt="image" src="https://github.com/apache/superset/assets/33317356/3734710a-5b98-45eb-9f76-de64789e36d3">
In addition, the tags filter was a freetext field, not a proper select (also fixed now).
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "john-bodley (via GitHub)" <gi...@apache.org>.
john-bodley commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1835164525
Though I believe @giftig's comment is now obsolete (per a self correction), regarding
> @villebro in my case I sometimes look for virtual datasets I've created by searching by creator. I don't think it's necessary for the list view (in fact I've only just noticed it's missing from there since "modified by" was generally the creator).
I think if we have a filter for an attribute, said attribute should appear in the table. The reason being is trust (or lack there of), i.e., if we're filtering by datasets created by Jane Doe then seeing Jane Doe's name in the result set under the appropriately name column serves as positive affirmation that the filters are working correctly.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1832795013
/testenv up FEATURE_TAGGING_SYSTEM=True
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1836959865
/testenv up FEATURE_TAGGING_SYSTEM=True FEATURE_ALERT_REPORTS=True
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "kgabryje (via GitHub)" <gi...@apache.org>.
kgabryje commented on code in PR #25961:
URL: https://github.com/apache/superset/pull/25961#discussion_r1410882295
##########
superset-frontend/src/pages/ChartList/index.tsx:
##########
@@ -438,44 +434,30 @@ function ChartList(props: ChartListProps) {
{
Cell: ({
row: {
- original: { last_saved_by: lastSavedBy },
+ original: { owners = [] },
},
- }: any) => <>{changedByName(lastSavedBy)}</>,
- Header: t('Modified by'),
- accessor: 'last_saved_by.first_name',
+ }: any) => <FacePile users={owners} />,
+ Header: t('Owners'),
+ accessor: 'owners',
+ disableSortBy: true,
size: 'xl',
},
{
Cell: ({
row: {
- original: { last_saved_at: lastSavedAt },
+ original: { last_saved_at: changedOn, last_saved_by: changedBy },
},
}: any) => (
- <span className="no-wrap">
- {lastSavedAt ? moment.utc(lastSavedAt).fromNow() : null}
- </span>
+ <AuditInfo
+ type={AuditInfoType.Modified}
+ date={changedOn}
Review Comment:
Nevermind, it was noted by Michael already 🙂
##########
superset-frontend/src/pages/ChartList/index.tsx:
##########
@@ -438,44 +434,30 @@ function ChartList(props: ChartListProps) {
{
Cell: ({
row: {
- original: { last_saved_by: lastSavedBy },
+ original: { owners = [] },
},
- }: any) => <>{changedByName(lastSavedBy)}</>,
- Header: t('Modified by'),
- accessor: 'last_saved_by.first_name',
+ }: any) => <FacePile users={owners} />,
+ Header: t('Owners'),
+ accessor: 'owners',
+ disableSortBy: true,
size: 'xl',
},
{
Cell: ({
row: {
- original: { last_saved_at: lastSavedAt },
+ original: { last_saved_at: changedOn, last_saved_by: changedBy },
},
}: any) => (
- <span className="no-wrap">
- {lastSavedAt ? moment.utc(lastSavedAt).fromNow() : null}
- </span>
+ <AuditInfo
+ type={AuditInfoType.Modified}
+ date={changedOn}
Review Comment:
Nevermind, it was noted by Michael already 🙂
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1832799253
@villebro Ephemeral environment spinning up at http://34.219.121.13:8080. Credentials are `admin`/`admin`. Please allow several minutes for bootstrapping and startup.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "giftig (via GitHub)" <gi...@apache.org>.
giftig commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1833408921
I just looked again, and I'm wrong; even in 2.1 I can't search datasets by creator, I'm actually searching by owner. I think this is fine then; I never even noticed the distinction between owner and creator when searching. We're also looking forward to getting tagging when we upgrade to 3.x, which will make searching for and categorising charts and dashboards more powerful anyway.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1832513218
> I have one concern about removing "created by" column. I think there is no other place (besides metadata bar in explore, but we don't have it in dashboards?) where you could see who created a dashboard or a chart + owners are not required I think. So if there are some random dashboards/charts it could be hard to find the right person to talk to about it if there is no information like this easily available. Thoughts?
Thanks for the review @kasiazjc ! ❤️ I agree that removal of "Created by" column may indeed be controversial. However, some reasoning behind this proposal:
- When a user creates a chart/dashboard/dataset, they always become the owner of it. It's only the sample assets that don't have an owner.
- We were already missing it in the Dataset list view.
- When a user creates a dashboard, they also automatically become the last modifier.
- I find that it's often of very limited utility to know who created a chart/dashboard - usually you really want to know who owns it, or who modified it last (the creator can often have left the team/org, hence may no longer be relevant, especially for long lived assets).
I'd be curious to hear thoughts from other users with big deployments - Ping @eschutho @sfirke @cccs-rc @john-bodley @michael-s-molina @giftig
Something to consider:
- We could add the filter for the creator, even without adding it to the list
- We may even add the creator to the hover of "Last modified". However, that may be confusing, so maybe that's not a great idea..
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "john-bodley (via GitHub)" <gi...@apache.org>.
john-bodley commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1832567128
Ha! @villebro I was just speaking to @michael-s-molina about this and how inconsistent these list views are. The columns and reorderings generally look great. A few comments:
1. I'm mixed about whether the creator (aka the first modifier) should remain and I think @villebro raised some good points in terms of why it should be removed. I sense the reason the creator was missing from a dataset is this was often misleading as for non-virtual datasets it merely is the person who registered the dataset.
2. You've renamed the dashboard `Title` column to `Name` (for consistency) and I was wondering whether this should be reflected throughout for consistency, i.e., in the modal when editing.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "john-bodley (via GitHub)" <gi...@apache.org>.
john-bodley commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1835233722
@michael-s-molina you previously mentioned,
> The filter is called `Chart Type` in the charts list but in the datasets list it's called `Type`
do you mean that the column is called `Visualization type`?
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on code in PR #25961:
URL: https://github.com/apache/superset/pull/25961#discussion_r1414316779
##########
superset-frontend/src/components/AuditInfo/index.tsx:
##########
@@ -0,0 +1,39 @@
+import React from 'react';
+
+import Owner from 'src/types/Owner';
+import { Tooltip } from 'src/components/Tooltip';
+import getOwnerName from 'src/utils/getOwnerName';
+import { t } from '@superset-ui/core';
+
+export const enum AuditInfoType {
+ Modified = 'Modified',
+ Created = 'Created',
+}
Review Comment:
Done
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1839370781
Ephemeral environment shutdown and build artifacts deleted.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "michael-s-molina (via GitHub)" <gi...@apache.org>.
michael-s-molina commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1836740161
> Thanks for the review comments @michael-s-molina - I've addressed all bugs/comments, but I'll still defer from reintroducing the creation columns until we decide on whether or not we want to keep it until 4.0.
@villebro I raised this question during the Town Hall and folks seem to be ok with removing the creator column in this PR.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1836956231
/testenv up FEATURE_TAGGING_SYSTEM=True
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1834128260
@michael-s-molina @kgabryje thanks for catching that non-humanized modified bug! I'll sort it out right away. Regarding Michael's comment:
> My suggestion would be to add a card to the [4.0 board](https://github.com/orgs/apache/projects/292) to remove the creator in the next major and for this PR, I would change the creator to be an avatar similar to the owners for consistency and to preserve real estate.
I think it would be confusing to use the avatars for both Owners and creators, and I believe that's the reason why creators/modifiers have been shown as text until now. If we do want to keep creators as a column, I propose we retain the username as-is, and not use the facepile component for them.
@kasiazjc how do you feel about showing creators as an avatar vs showing it as the full name as text (current behavior)?
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1835072449
> * The filter is called `Owner` but the list header is `Owners` (plural).
> * Some filters use plural form and others use singular form in a inconsistent manner. I believe the nomenclature here should reflect the filter type. Singular for filters that allow only one value and plural for filters that allow multiple values.
I've updated these so that the single select filters are now singular (Tag, Owner).
> * `Last modified` generally has the form of `15 hours ago` but in the charts list it's `2023-11-30T13:53:56.840190`
Good catch - fixed.
> * The filter is called `Chart Type` in the charts list but in the datasets list it's called `Type`
Renamed to "Type" throughout.
> * The filter in the tags list is called `Search` instead of `Name`
Renamed to "Name".
> * In the database list the column is called `Name` but in the modal it's called `Display name`
Renamed "Display name" to "Name" in the modal.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1835438858
@villebro Ephemeral environment spinning up at http://34.222.153.32:8080. Credentials are `admin`/`admin`. Please allow several minutes for bootstrapping and startup.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro merged PR #25961:
URL: https://github.com/apache/superset/pull/25961
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on code in PR #25961:
URL: https://github.com/apache/superset/pull/25961#discussion_r1399986203
##########
superset-frontend/src/components/AsyncAceEditor/index.tsx:
##########
@@ -25,6 +25,7 @@ import {
} from 'brace';
import AceEditor, { IAceEditorProps } from 'react-ace';
import { acequire } from 'ace-builds/src-noconflict/ace';
+import 'ace-builds/webpack-resolver';
Review Comment:
Without this we get a failed network request when opening up the edit modal in the CSS list view + no syntax highlighting (it's even uglier with `dev-server`):
<img width="1204" alt="image" src="https://github.com/apache/superset/assets/33317356/2060c2e7-bf6c-4105-996a-72aaeced9819">
After adding this, no more failed network request + CSS syntax highlighting works:
<img width="1206" alt="image" src="https://github.com/apache/superset/assets/33317356/8a73df2b-cece-4959-95c2-3546e03eea5d">
Adding this import was a recommendation in this thread, and seemed to be an ok fix: https://github.com/securingsincity/react-ace/issues/725
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on code in PR #25961:
URL: https://github.com/apache/superset/pull/25961#discussion_r1411441065
##########
superset-frontend/src/pages/SavedQueryList/index.tsx:
##########
@@ -497,28 +489,22 @@ function SavedQueryList({
),
paginate: true,
},
-
- {
- Header: t('Search'),
- id: 'label',
- key: 'search',
- input: 'search',
- operator: FilterOperator.allText,
- },
+ ...(isFeatureEnabled(FeatureFlag.TAGGING_SYSTEM) && canReadTag
+ ? [
+ {
+ Header: t('Tag'),
+ id: 'tags',
+ key: 'tags',
+ input: 'select',
+ operator: FilterOperator.savedQueryTags,
+ fetchSelects: loadTags,
+ },
+ ]
+ : []),
],
[addDangerToast],
);
- if (isFeatureEnabled(FeatureFlag.TAGGING_SYSTEM) && canReadTag) {
- filters.push({
- Header: t('Tags'),
- id: 'tags',
- key: 'tags',
- input: 'search',
- operator: FilterOperator.savedQueryTags,
- });
- }
-
Review Comment:
This was done outside the useMemo, causing the tags filter to get appended multiple times to the filter array:
<img width="1163" alt="image" src="https://github.com/apache/superset/assets/33317356/3734710a-5b98-45eb-9f76-de64789e36d3">
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "john-bodley (via GitHub)" <gi...@apache.org>.
john-bodley commented on code in PR #25961:
URL: https://github.com/apache/superset/pull/25961#discussion_r1411485384
##########
superset-frontend/cypress-base/cypress/e2e/chart_list/list.test.ts:
##########
@@ -109,14 +109,12 @@ describe('Charts list', () => {
it('should load rows in list mode', () => {
cy.getBySel('listview-table').should('be.visible');
- cy.getBySel('sort-header').eq(1).contains('Chart');
+ cy.getBySel('sort-header').eq(1).contains('Name');
cy.getBySel('sort-header').eq(2).contains('Visualization type');
Review Comment:
```suggestion
cy.getBySel('sort-header').eq(2).contains('Type');
```
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "kasiazjc (via GitHub)" <gi...@apache.org>.
kasiazjc commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1833386622
> > I have one concern about removing "created by" column. I think there is no other place (besides metadata bar in explore, but we don't have it in dashboards?) where you could see who created a dashboard or a chart + owners are not required I think. So if there are some random dashboards/charts it could be hard to find the right person to talk to about it if there is no information like this easily available. Thoughts?
>
> Thanks for the review @kasiazjc ! ❤️ I agree that removal of "Created by" column may indeed be controversial. However, some reasoning behind this proposal:
>
> * We have very limited screen real estate, and this is a major issue especially when the Tagging system is enabled.
> * When a user creates a chart/dashboard/dataset, they always become the owner of it. It's only the sample assets that don't have an owner.
> * We were already missing it in the Dataset list view.
> * When a user creates a dashboard, they also automatically become the last modifier.
> * I find that it's often of very limited utility to know who created a chart/dashboard - usually you really want to know who owns it, or who modified it last (the creator can often have left the team/org, hence may no longer be relevant, especially for long lived assets).
>
> I'd be curious to hear thoughts from other users with big deployments - Ping @eschutho @sfirke @cccs-rc @john-bodley @michael-s-molina @giftig
>
> Something to consider:
>
> * We could add the filter for the creator, even without adding it to the list
> * We may even add the creator to the hover of "Last modified". However, that may be confusing, so maybe that's not a great idea..
That makes sense to me! Consider me convinced. Thank you 🩵
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1835436520
/testenv up
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "sfirke (via GitHub)" <gi...@apache.org>.
sfirke commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1834304609
These changes all look excellent to me! We don't use the "created by" field and I'd be happy to see it gone.
To me it's right on the borderline of being a tiny breaking change or not, I don't feel strongly if that part is held off for 4.0 or done now. If it's easy to pull that part out for 4.0, great, if it's significant extra work then I'd just say merge 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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "michael-s-molina (via GitHub)" <gi...@apache.org>.
michael-s-molina commented on code in PR #25961:
URL: https://github.com/apache/superset/pull/25961#discussion_r1414004557
##########
superset-frontend/src/components/AuditInfo/index.tsx:
##########
@@ -0,0 +1,39 @@
+import React from 'react';
+
+import Owner from 'src/types/Owner';
+import { Tooltip } from 'src/components/Tooltip';
+import getOwnerName from 'src/utils/getOwnerName';
+import { t } from '@superset-ui/core';
+
+export const enum AuditInfoType {
+ Modified = 'Modified',
+ Created = 'Created',
+}
Review Comment:
I think we can remove this enum and even change the component's name given that we don't have references to `Created` anymore.
##########
superset-frontend/src/components/AuditInfo/AuditInfo.test.tsx:
##########
@@ -0,0 +1,64 @@
+import React from 'react';
+import { render, screen, waitFor } from '@testing-library/react';
+import '@testing-library/jest-dom';
+import userEvent from '@testing-library/user-event';
+
+import { supersetTheme, ThemeProvider } from '@superset-ui/core';
+import { AuditInfo, AuditInfoProps, AuditInfoType } from '.';
+
+const TEST_DATE = '2023-11-20';
+const USER = {
+ id: 1,
+ first_name: 'Foo',
+ last_name: 'Bar',
+};
+
+const Wrapper: React.FC<AuditInfoProps> = ({ type, user, date }) => (
Review Comment:
You don't need to manually do this. You can use our [test helper](https://github.com/apache/superset/blob/master/superset-frontend/spec/helpers/testing-library.tsx) which always adds the theme provider:
```
import { render, screen, waitFor } from 'spec/helpers/testing-library';
render(<AuditInfo type={type} user={user} date={date} />);
```
The same helper can be used to set redux, dnd, query params, router, etc.
```
render(<Component {...props} />, { useRedux: true, useDnd: true });
```
##########
superset-frontend/src/utils/getOwnerName.test.ts:
##########
@@ -0,0 +1,26 @@
+/**
+ * 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 getOwnerName from './getOwnerName';
+
+test('render owner name', () => {
Review Comment:
I generally like to treat these as separate test cases as they give you more accuracy when reading test results.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1832369645
@villebro Ephemeral environment spinning up at http://35.92.246.119:8080. Credentials are `admin`/`admin`. Please allow several minutes for bootstrapping and startup.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1832364782
/testenv up
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "kgabryje (via GitHub)" <gi...@apache.org>.
kgabryje commented on code in PR #25961:
URL: https://github.com/apache/superset/pull/25961#discussion_r1410862910
##########
superset-frontend/src/pages/ChartList/index.tsx:
##########
@@ -438,44 +434,30 @@ function ChartList(props: ChartListProps) {
{
Cell: ({
row: {
- original: { last_saved_by: lastSavedBy },
+ original: { owners = [] },
},
- }: any) => <>{changedByName(lastSavedBy)}</>,
- Header: t('Modified by'),
- accessor: 'last_saved_by.first_name',
+ }: any) => <FacePile users={owners} />,
+ Header: t('Owners'),
+ accessor: 'owners',
+ disableSortBy: true,
size: 'xl',
},
{
Cell: ({
row: {
- original: { last_saved_at: lastSavedAt },
+ original: { last_saved_at: changedOn, last_saved_by: changedBy },
},
}: any) => (
- <span className="no-wrap">
- {lastSavedAt ? moment.utc(lastSavedAt).fromNow() : null}
- </span>
+ <AuditInfo
+ type={AuditInfoType.Modified}
+ date={changedOn}
Review Comment:
Shouldn't we use `changed_on_delta_humanized` here? I'm seeing an inconsistency between ChartList and for example DashboardList
<img width="1695" alt="image" src="https://github.com/apache/superset/assets/15073128/25d8eb9d-a96b-4a40-b0c8-8205a9f8d9dc">
<img width="1728" alt="image" src="https://github.com/apache/superset/assets/15073128/eed473f7-99c4-4b9d-a985-64459c122d9a">
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1836924987
> > Thanks for the review comments @michael-s-molina - I've addressed all bugs/comments, but I'll still defer from reintroducing the creation columns until we decide on whether or not we want to keep it until 4.0.
>
> @villebro I raised this question during the Town Hall and folks seem to be ok with removing the creator column in this PR.
Thanks for raising this @michael-s-molina ! To strike a compromise, I introduced a "Modified by" filter to make it possible to search based on the last modifier. I'll update the screens to reflect this and ping you for a final review once CI is green.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on code in PR #25961:
URL: https://github.com/apache/superset/pull/25961#discussion_r1414316380
##########
superset-frontend/src/components/AuditInfo/AuditInfo.test.tsx:
##########
@@ -0,0 +1,64 @@
+import React from 'react';
+import { render, screen, waitFor } from '@testing-library/react';
+import '@testing-library/jest-dom';
+import userEvent from '@testing-library/user-event';
+
+import { supersetTheme, ThemeProvider } from '@superset-ui/core';
+import { AuditInfo, AuditInfoProps, AuditInfoType } from '.';
+
+const TEST_DATE = '2023-11-20';
+const USER = {
+ id: 1,
+ first_name: 'Foo',
+ last_name: 'Bar',
+};
+
+const Wrapper: React.FC<AuditInfoProps> = ({ type, user, date }) => (
Review Comment:
Thanks, I didn't know about this, very helpful and much cleaner!
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1836958573
@villebro Ephemeral environment spinning up at http://34.222.234.40:8080. Credentials are `admin`/`admin`. Please allow several minutes for bootstrapping and startup.
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on code in PR #25961:
URL: https://github.com/apache/superset/pull/25961#discussion_r1414319174
##########
superset-frontend/src/utils/getOwnerName.test.ts:
##########
@@ -0,0 +1,26 @@
+/**
+ * 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 getOwnerName from './getOwnerName';
+
+test('render owner name', () => {
Review Comment:
Good idea, done
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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
Re: [PR] chore: harmonize and clean up list views [superset]
Posted by "villebro (via GitHub)" <gi...@apache.org>.
villebro commented on PR #25961:
URL: https://github.com/apache/superset/pull/25961#issuecomment-1832449371
/testenv up FEATURE_TAGGING_SYSTEM=True
--
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.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
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