Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Model version and details archive #2815

Merged

Conversation

dpanshug
Copy link
Contributor

@dpanshug dpanshug commented May 15, 2024

RHOAIENG-6639
RHOAIENG-6640

Description

Archiving model versions.

See below video for archiving and restoring flow, along with archive model version table and details view.
Screencast from 2024-05-20 16-07-17.webm

How Has This Been Tested?

  1. Move to model registry section and open a register model.
  2. Try archiving and restoring model version.

Test Impact

Added unit tests and cypress tests

Request review criteria:

Self checklist (all need to be checked):

  • The developer has manually tested the changes and verified that the changes work
  • Commits have been squashed into descriptive, self-contained units of work (e.g. 'WIP' and 'Implements feedback' style messages have been removed)
  • Testing instructions have been added in the PR body (for PRs involving changes that are not immediately obvious).
  • The developer has added tests or explained why testing cannot be added (unit or cypress tests for related changes)

If you have UI changes:

  • Included any necessary screenshots or gifs if it was a UI change.
  • Included tags to the UX team if it was a UI/UX change (find relevant UX in the SMEs section).

After the PR is posted & before it merges:

  • The developer has tested their solution on a cluster by using the image produced by the PR to main

@yih-wang

@dpanshug dpanshug changed the title Model version and details archive [WIP] Model version and details archive May 15, 2024
@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress This PR is in WIP state label May 15, 2024
@dpanshug
Copy link
Contributor Author

WIP because working on cypress test

@yih-wang
Copy link

Thanks @dpanshug for all the work! That looks great!

Several comments:

  • After a version is restored, the user should be navigated to the version details page rather than the versions list. That will provide convenience for the following actions to that version.
  • Not sure whether that should be fixed here, but in the empty state of the versions list, the link button should be put under the primary button, rather than next to each other. That follows the PF guidelines.
  • I've noticed numerous tooltips are appearing when interacting with the interface. Are these tooltips part of the default PF template? It seems like they are too much and not necessary in all cases. Is that possible to display only the tooltips specified in the designs?
image image

@openshift-merge-robot openshift-merge-robot added the needs-rebase PR needs to be rebased label May 19, 2024
@openshift-merge-robot openshift-merge-robot removed the needs-rebase PR needs to be rebased label May 20, 2024
@dpanshug dpanshug changed the title [WIP] Model version and details archive Model version and details archive May 20, 2024
@openshift-ci openshift-ci bot removed the do-not-merge/work-in-progress This PR is in WIP state label May 20, 2024
@dpanshug
Copy link
Contributor Author

@yih-wang Pls check the latest screencast video.

After a version is restored, the user should be navigated to the version details page rather than the versions list. That will provide convenience for the following actions to that version.

I've updated this so restoring from the details page navigates to the version details page. Should the same happen when restoring from the Archive version table?

Not sure whether that should be fixed here, but in the empty state of the versions list, the link button should be put under the primary button, rather than next to each other. That follows the PF guidelines.

Corrected this.

I've noticed numerous tooltips are appearing when interacting with the interface. Are these tooltips part of the default PF template? It seems like they are too much and not necessary in all cases. Is that possible to display only the tooltips specified in the designs?

That's because we are using Truncate component for the name. I am not sure if we can remove the unwanted tooltip. cc @lucferbux

Copy link
Contributor

@lucferbux lucferbux left a comment

Choose a reason for hiding this comment

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

There are a couples of nits in the code, haven't had the time to properly test the functionality, will do tomorrow, tests seemed great!

@yih-wang
Copy link

@dpanshug Thanks for all the updates! The new video looks good.

I've updated this so restoring from the details page navigates to the version details page. Should the same happen when restoring from the Archive version table?

Yes, lets keep both flows ending up with the details page.

That's because we are using Truncate component for the name. I am not sure if we can remove the unwanted tooltip. cc @lucferbux

What makes sense to me is only the truncated names have hovering tooltips. Not sure whether it's an easy way to estimate whether it's a truncated name or not. Can we remove the tooltip also for the field below? Seems it's not due to the truncate component.
image

@lucferbux
Copy link
Contributor

lucferbux commented May 21, 2024

What makes sense to me is only the truncated names have hovering tooltips. Not sure whether it's an easy way to estimate whether it's a truncated name or not. Can we remove the tooltip also for the field below? Seems it's not due to the truncate component. image

@yih-wang @dpanshug Oh i assumed that wasn't a tooltip but a native autofiller in the browser, let me review the code but I couldn't recall a tooltip in the confirmation modal

@yih-wang
Copy link

@lucferbux Ah yes, the one in the confirmation modal might be a browser-native component. It looks different from the tooltip above.

@lucferbux
Copy link
Contributor

That's because we are using Truncate component for the name. I am not sure if we can remove the unwanted tooltip. cc @lucferbux
I was assuming we are mostly reusing what we have in other views, if we have tooltips and truncate text in say model serving and pipelines we should stick to that.

@yih-wang
Copy link

I was assuming we are mostly reusing what we have in other views, if we have tooltips and truncate text in say model serving and pipelines we should stick to that.

Agree. I'm fine if all the other places do the same thing. We could just follow the pattern and improve this as a whole in the future.

@dpanshug
Copy link
Contributor Author

@yih-wang, updated the restore navigation also in archive table.
Screencast from 2024-05-21 14-42-53.webm

@dpanshug dpanshug force-pushed the model-version-archive branch 4 times, most recently from c0db81b to 05c61ff Compare May 22, 2024 11:26
Copy link

codecov bot commented May 22, 2024

Codecov Report

Attention: Patch coverage is 87.43961% with 26 lines in your changes are missing coverage. Please review.

Project coverage is 77.46%. Comparing base (bac0976) to head (daa6e6f).
Report is 17 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2815      +/-   ##
==========================================
+ Coverage   77.40%   77.46%   +0.06%     
==========================================
  Files        1101     1108       +7     
  Lines       23192    23383     +191     
  Branches     5848     5882      +34     
==========================================
+ Hits        17951    18114     +163     
- Misses       5241     5269      +28     
Files Coverage Δ
...rc/pages/modelRegistry/ModelRegistryCoreLoader.tsx 72.22% <ø> (ø)
...nd/src/pages/modelRegistry/ModelRegistryRoutes.tsx 66.66% <ø> (ø)
.../src/pages/modelRegistry/screens/ModelRegistry.tsx 62.50% <ø> (ø)
...creens/ModelVersionDetails/ModelVersionDetails.tsx 95.65% <ø> (ø)
...nDetails/ModelVersionRegisteredDeploymentsView.tsx 100.00% <ø> (ø)
...elRegistry/screens/ModelVersions/ModelVersions.tsx 93.75% <100.00%> (ø)
...screens/ModelVersions/ModelVersionsTableColumns.ts 100.00% <100.00%> (+40.00%) ⬆️
...gistry/screens/ModelVersions/ModelVersionsTabs.tsx 90.00% <100.00%> (+1.11%) ⬆️
...odelVersionsArchive/ModelVersionArchiveDetails.tsx 100.00% <100.00%> (ø)
...try/screens/components/EmptyModelRegistryState.tsx 92.85% <ø> (ø)
... and 12 more

... and 7 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update bac0976...daa6e6f. Read the comment docs.

Copy link
Contributor

@manaswinidas manaswinidas left a comment

Choose a reason for hiding this comment

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

/lgtm Thanks for making all the changes.

@openshift-ci openshift-ci bot added the lgtm label May 23, 2024
@openshift-ci openshift-ci bot removed the lgtm label May 23, 2024
@dpanshug dpanshug force-pushed the model-version-archive branch 2 times, most recently from bd26915 to 962f6bc Compare May 23, 2024 13:27
@manaswinidas
Copy link
Contributor

/lgtm

@openshift-ci openshift-ci bot added the lgtm label May 23, 2024
Copy link
Contributor

@lucferbux lucferbux left a comment

Choose a reason for hiding this comment

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

/lgtm

Copy link
Contributor

openshift-ci bot commented May 27, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: lucferbux, manaswinidas

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@lucferbux
Copy link
Contributor

/retest

It seems a problem with cypress and the cdn

@lucferbux
Copy link
Contributor

/retest

@openshift-merge-bot openshift-merge-bot bot merged commit 371793a into opendatahub-io:main May 28, 2024
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants