Skip to content

Add public datasets under "Hub" - #3129

Merged
GspikeHalo merged 39 commits into
masterfrom
add-public-dataset
Jan 22, 2025
Merged

GspikeHalo merged 39 commits into
masterfrom
add-public-dataset

Conversation

@GspikeHalo

@GspikeHalo GspikeHalo commented Nov 30, 2024 •

Copy link
Copy Markdown
Contributor

Purpose:

Added a new interface for public datasets, allowing non-logged-in users to view datasets shared by others. The behavior of public datasets aligns with that of public workflows, ensuring consistent access and interaction with public resources.

Changes:

  1. Added "Hub Dataset" to the left sidebar. Clicking on it will display public datasets.
  2. Updated the list item behavior: When a user clicks a list item of type "dataset," different navigation actions are taken depending on the situation:
    • If the user is not logged in, they will always be redirected to the Hub Dataset page. This page disables the download
      functionality and does not display the publish switch.
    • If the user is logged in but lacks direct access permissions (e.g., read or write), they will still be redirected to the Hub Dataset page.
    • If the user is logged in and has read or write permissions, they will be redirected to the User Dataset page, which is the original dataset page we had.

Demos:

Before:
Left sidebar:
image

After:
Left sidebar:
image

Public Dataset Interface Before Login:
image

Public Dataset Interface After Login:
image

Non-logged-in user clicking any dataset:
image

Logged-in user without direct permissions clicking any dataset:
image

Logged-in user with direct permissions clicking any dataset:
image

@GspikeHalo
GspikeHalo marked this pull request as ready for review December 18, 2024 03:55
@GspikeHalo
GspikeHalo changed the base branch from master to update-dataset-workflow-table December 18, 2024 05:55
@GspikeHalo
GspikeHalo changed the base branch from update-dataset-workflow-table to master December 18, 2024 05:55
@GspikeHalo GspikeHalo added the frontend Changes related to the frontend GUI label Jan 8, 2025
@GspikeHalo
GspikeHalo requested a review from chenlica January 11, 2025 22:15
@GspikeHalo
GspikeHalo marked this pull request as draft January 17, 2025 05:01
@GspikeHalo GspikeHalo changed the title Add public datasets under "Community" Add public datasets under "Hub" Jan 17, 2025
@GspikeHalo
GspikeHalo marked this pull request as ready for review January 17, 2025 09:07
Comment thread core/gui/src/app/app-routing.module.ts Resolved

@aglinxinyuan aglinxinyuan left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@GspikeHalo
GspikeHalo merged commit 460e078 into master Jan 22, 2025
@GspikeHalo
GspikeHalo deleted the add-public-dataset branch January 22, 2025 06:22
Ma77Ball pushed a commit that referenced this pull request Apr 2, 2025
### Purpose:
Added a new interface for public datasets, allowing non-logged-in users
to view datasets shared by others. The behavior of public datasets
aligns with that of public workflows, ensuring consistent access and
interaction with public resources.

### Changes:
1. Added "Hub Dataset" to the left sidebar. Clicking on it will display
public datasets.
2. Updated the list item behavior: When a user clicks a list item of
type "dataset," different navigation actions are taken depending on the
situation:
- If the user is not logged in, they will always be redirected to the
Hub Dataset page. This page disables the download
functionality and does not display the publish switch.
- If the user is logged in but lacks direct access permissions (e.g.,
read or write), they will still be redirected to the Hub Dataset page.
- If the user is logged in and has read or write permissions, they will
be redirected to the User Dataset page, which is the original dataset
page we had.

### Demos:
**Before:**
Left sidebar:

![image](https://github.com/user-attachments/assets/4d461f79-1a5d-4e65-b6d9-08c55005410d)

**After:**
Left sidebar:

![image](https://github.com/user-attachments/assets/a468cbe7-f40f-40f1-8458-4b5c39ad056a)

Public Dataset Interface Before Login:

![image](https://github.com/user-attachments/assets/89819585-e401-43f6-82bb-8fcb50dace1f)

Public Dataset Interface After Login:

![image](https://github.com/user-attachments/assets/0c0ad66f-764d-4261-9137-0ae433cfd38a)

Non-logged-in user clicking any dataset:

![image](https://github.com/user-attachments/assets/04643d12-57af-4b94-bbb6-331db13ae038)

Logged-in user without direct permissions clicking any dataset:

![image](https://github.com/user-attachments/assets/ce693abc-a6b3-47cc-8b5f-63c0b5e24f62)

Logged-in user with direct permissions clicking any dataset:

![image](https://github.com/user-attachments/assets/df28fd0b-9992-4e40-b480-ec83bfe3dc9d)
SarahAsad23 pushed a commit to madisonmlin/texera that referenced this pull request May 20, 2026
### Purpose:
Added a new interface for public datasets, allowing non-logged-in users
to view datasets shared by others. The behavior of public datasets
aligns with that of public workflows, ensuring consistent access and
interaction with public resources.

### Changes:
1. Added "Hub Dataset" to the left sidebar. Clicking on it will display
public datasets.
2. Updated the list item behavior: When a user clicks a list item of
type "dataset," different navigation actions are taken depending on the
situation:
- If the user is not logged in, they will always be redirected to the
Hub Dataset page. This page disables the download
functionality and does not display the publish switch.
- If the user is logged in but lacks direct access permissions (e.g.,
read or write), they will still be redirected to the Hub Dataset page.
- If the user is logged in and has read or write permissions, they will
be redirected to the User Dataset page, which is the original dataset
page we had.

### Demos:
**Before:**
Left sidebar:

![image](https://github.com/user-attachments/assets/4d461f79-1a5d-4e65-b6d9-08c55005410d)

**After:**
Left sidebar:

![image](https://github.com/user-attachments/assets/a468cbe7-f40f-40f1-8458-4b5c39ad056a)

Public Dataset Interface Before Login:

![image](https://github.com/user-attachments/assets/89819585-e401-43f6-82bb-8fcb50dace1f)

Public Dataset Interface After Login:

![image](https://github.com/user-attachments/assets/0c0ad66f-764d-4261-9137-0ae433cfd38a)

Non-logged-in user clicking any dataset:

![image](https://github.com/user-attachments/assets/04643d12-57af-4b94-bbb6-331db13ae038)

Logged-in user without direct permissions clicking any dataset:

![image](https://github.com/user-attachments/assets/ce693abc-a6b3-47cc-8b5f-63c0b5e24f62)

Logged-in user with direct permissions clicking any dataset:

![image](https://github.com/user-attachments/assets/df28fd0b-9992-4e40-b480-ec83bfe3dc9d)
yangzhang75 pushed a commit to yangzhang75/texera that referenced this pull request Jun 22, 2026
### Purpose:
Added a new interface for public datasets, allowing non-logged-in users
to view datasets shared by others. The behavior of public datasets
aligns with that of public workflows, ensuring consistent access and
interaction with public resources.

### Changes:
1. Added "Hub Dataset" to the left sidebar. Clicking on it will display
public datasets.
2. Updated the list item behavior: When a user clicks a list item of
type "dataset," different navigation actions are taken depending on the
situation:
- If the user is not logged in, they will always be redirected to the
Hub Dataset page. This page disables the download
functionality and does not display the publish switch.
- If the user is logged in but lacks direct access permissions (e.g.,
read or write), they will still be redirected to the Hub Dataset page.
- If the user is logged in and has read or write permissions, they will
be redirected to the User Dataset page, which is the original dataset
page we had.

### Demos:
**Before:**
Left sidebar:

![image](https://github.com/user-attachments/assets/4d461f79-1a5d-4e65-b6d9-08c55005410d)

**After:**
Left sidebar:

![image](https://github.com/user-attachments/assets/a468cbe7-f40f-40f1-8458-4b5c39ad056a)

Public Dataset Interface Before Login:

![image](https://github.com/user-attachments/assets/89819585-e401-43f6-82bb-8fcb50dace1f)

Public Dataset Interface After Login:

![image](https://github.com/user-attachments/assets/0c0ad66f-764d-4261-9137-0ae433cfd38a)

Non-logged-in user clicking any dataset:

![image](https://github.com/user-attachments/assets/04643d12-57af-4b94-bbb6-331db13ae038)

Logged-in user without direct permissions clicking any dataset:

![image](https://github.com/user-attachments/assets/ce693abc-a6b3-47cc-8b5f-63c0b5e24f62)

Logged-in user with direct permissions clicking any dataset:

![image](https://github.com/user-attachments/assets/df28fd0b-9992-4e40-b480-ec83bfe3dc9d)
renovate-bot pushed a commit to renovate-bot/apache-_-texera that referenced this pull request Nov 17, 2026
### What changes were proposed in this PR?

Remove unreachable code from dataset creation, dashboard search, and
file previews, and rename the dataset creator to match the model
creator. **+245/−388 lines across fourteen files.**

- The dashboard and result export both open the modal to create a
dataset. Versions are created on the dataset detail page, so the shared
creator form always shows its visibility and downloadability switches.
- With only dataset creation left, `UserDatasetVersionCreatorComponent`
becomes `UserDatasetCreatorComponent` and moves from
`user-dataset-explorer/` to `user-dataset/user-dataset-creator/`,
matching `UserModelCreatorComponent` in
`user-model/user-model-creator/`. GitHub shows its `.ts` as a new file
because the move and the version-mode removal together change most of
it.
- Dashboard search has no callers for the public or all scopes.
- HTML, PDF, MS Word, and MS PowerPoint suffixes already fall through to
the unsupported-preview notice. The preview guard rejects binary files
before the size lookup, and every type it accepts has its own size
limit, so the default limit is never used.

| Code | Introduced by | Usage removed by |
| --- | --- | --- |
| Modal version mode | apache#3296 | apache#3659 |
| Creator form switch toggle | apache#2413 | apache#3659 |
| Dashboard search scopes | apache#2987 | apache#3129 |
| Binary preview size limit | apache#2413 | apache#3149 |
| Default preview size limit | apache#2413, apache#3427 | Never reached |
| Unsupported MIME aliases | apache#2413 | Never selected a viewer |

The modal mode and its switch toggle have been unreachable since August
2025, the search scopes since January 2025, and the binary size limit
since December 2024.

### Any related issues, documentation, discussions?

Closes apache#9462.

### How was this PR tested?

From `frontend/` on Node 24

```sh
NODE_OPTIONS=--max-old-space-size=8192 yarn test --progress=false \
  --include='**/{user-dataset-file-renderer,user-dataset-creator,user-model-creator,user-dataset,result-exportation,result-table-frame,context-menu,dataset-detail,version-uploader}.component.spec.ts'
yarn exec tsc --noEmit -p src/tsconfig.app.json
yarn exec tsc --noEmit -p src/tsconfig.spec.json
yarn format:ci
yarn build
```

509 tests passed across nine suites. The preview test now checks that
the four affected suffixes still show the unsupported-preview state
without a request to the backend. Both creation entry points, the model
creator that shares the creator form, and the dataset version uploader
are covered by the targeted run.

### Was this PR authored or co-authored using generative AI tooling?

Generated-by: Codex (GPT-6) and Claude Code (Claude Opus 5.5)

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

frontend Changes related to the frontend GUI

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants