mikebridge opened a new pull request, #43465:
URL: https://github.com/apache/superset/pull/43465

   ### SUMMARY
   
   On the **Recently Archived** (soft-delete recovery) view, the 
archived-object type was labeled **"Dataset"** — in the type-filter dropdown 
and the Type column — even on workspaces where the `SEMANTIC_LAYERS` feature 
flag renames the concept to **"Datasource"** everywhere else (the top nav reads 
"Datasources" while the archived row says "Dataset"). QA-reported cosmetic 
inconsistency (sc-117448).
   
   Root cause: the view's `TYPE_LABELS` map was a module-level constant with 
`dataset: t('Dataset')` hardcoded, bypassing the app's flag-aware naming 
module. The map now holds label **getters** (`Record<ArchivedType, () => 
string>`) and the dataset entry delegates to the existing shared helper 
(`datasetLabel` from `src/features/semanticLayers/label.ts`), so the flag is 
read at render time and any future rename stays consistent automatically.
   
   Only display text changes: the `ArchivedType` identifiers, filter values, 
and API requests are byte-identical under both flag states (asserted in the 
tests — selecting the renamed option still drives the dataset endpoints). With 
the flag off, every string renders exactly as before.
   
   Docs: the Recently Archived page's Type-selector sentence now notes the 
flag-aware name.
   
   ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
   
   Before (from the ticket, flag ON — nav says "Datasources", archived type 
says "Dataset"): see [sc-117448's 
screenshot](https://media.app.shortcut.com/api/attachments/files/clubhouse-assets/5d8baaab-e1a8-4512-a9c7-12979c8cd1c9/6a7f4a52-cc80-49f1-bbff-c59edf98cead/Screenshot%202026-08-14%20at%2013.37.54.png).
 After: the same two spots read "Datasource"; with the flag off, "Dataset" 
(unchanged). Text-only change; RTL tests pin both states.
   
   ### TESTING INSTRUCTIONS
   
   1. Enable `SOFT_DELETE` and `SEMANTIC_LAYERS` (top nav shows 
**Datasources**); archive a dataset.
   2. Settings → **Recently Archived**: the Type selector offers **Datasource** 
(with Chart/Dashboard) and the Type column reads **Datasource**; selecting it 
lists the archived datasets exactly as the "Dataset" option did.
   3. Disable `SEMANTIC_LAYERS`: both spots read **Dataset**, unchanged from 
before this PR.
   4. `npm run test -- src/pages/ArchivedList` — 23 tests including the two new 
flag-state tests (the flag-on assertion fails against the previous hardcoded 
map).
   
   ### ADDITIONAL INFORMATION
   - [ ] Has associated issue:
   - [x] Required feature flags: `SEMANTIC_LAYERS` for the renamed label 
(`SOFT_DELETE` to reach the view); flag-off rendering unchanged
   - [x] 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
   
   🤖 Authored with the assistance of Claude (AI), directed and reviewed by 
@mikebridge.
   


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to