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

fix: ensure tokens consistency after editing and redeploying. #3768

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

mtalvi
Copy link
Contributor

@mtalvi mtalvi commented Feb 17, 2025

Related to the following:
https://issues.redhat.com/browse/NVPE-154
https://issues.redhat.com/browse/NVPE-156

Description

Fix to ensure tokens consistency after editing and redeploying.

How Has This Been Tested?

Tested locally.

Test Impact

There are 2 main scenarios to be checked:
Model was initially deployed without any tokens and token authentication was added via edit:

  1. Enable NIM
  2. Go to Data Science Project
  3. Click on the existing or create a new project
  4. Go to models and deploy a model with token authentication unchecked.
  5. Edit the model you created and add token authentication (this will create a token) and redeploy.
  6. Make sure the token created is displayed in the dashboard.

Model was initially deployed with token authentication and another new token was added via edit:

  1. Enable NIM
  2. Go to Data Science Project
  3. Click on the existing or create a new project
  4. Go to models and deploy a model with token authentication checked (this will create a token).
  5. Make sure the token created is displayed in the dashboard
  6. Edit the model you created and add a new token and redeploy.
  7. Make sure the token created is displayed in the dashboard in addition to any previous token.

Screenshot of the relevant dashboard:
image

Request review criteria:

Self checklist (all need to be checked):

  • The developer has manually tested the changes and verified that the changes work
  • 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.

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

Copy link
Contributor

openshift-ci bot commented Feb 17, 2025

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign manosnoam for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found 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

Copy link
Contributor

openshift-ci bot commented Feb 17, 2025

Hi @mtalvi. Thanks for your PR.

I'm waiting for a opendatahub-io member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@openshift-ci openshift-ci bot added the needs-ok-to-test The openshift bot needs to label PRs from non members to avoid strain on the CI label Feb 17, 2025
Copy link

codecov bot commented Feb 17, 2025

Codecov Report

Attention: Patch coverage is 78.94737% with 4 lines in your changes missing coverage. Please review.

Project coverage is 84.62%. Comparing base (9b6b7a6) to head (fabacfb).

Files with missing lines Patch % Lines
frontend/src/pages/modelServing/utils.ts 78.94% 4 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #3768      +/-   ##
==========================================
- Coverage   84.63%   84.62%   -0.01%     
==========================================
  Files        1515     1515              
  Lines       35100    35110      +10     
  Branches     9814     9820       +6     
==========================================
+ Hits        29707    29713       +6     
- Misses       5393     5397       +4     
Files with missing lines Coverage Δ
...ntend/src/pages/projects/ProjectDetailsContext.tsx 88.63% <ø> (ø)
frontend/src/pages/modelServing/utils.ts 92.77% <78.94%> (-1.34%) ⬇️

... and 6 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 9b6b7a6...fabacfb. Read the comment docs.

@emilys314
Copy link
Contributor

/ok-to-test

@openshift-ci openshift-ci bot added ok-to-test The openshift bot needs `ok-to-test` to allow non member PRs to run the tests. and removed needs-ok-to-test The openshift bot needs to label PRs from non members to avoid strain on the CI labels Feb 17, 2025
@emilys314
Copy link
Contributor

Doing non NIM deployments with auth doesn't seem to work anymore.

image

@mtalvi
Copy link
Contributor Author

mtalvi commented Feb 19, 2025

Doing non NIM deployments with auth doesn't seem to work anymore.

image

I have tried to deploy non NIM deployments with auth and it went ok. Maybe there was a temporary issue when you tried. I'm attaching the video:

non-nim-auth.mp4

@emilys314
Copy link
Contributor

I have tried to deploy non NIM deployments with auth and it went ok. Maybe there was a temporary issue when you tried. I'm attaching the video:

If you add a space in the model name it will fail, I believe it's because translateDisplayNameForK8s was removed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ok-to-test The openshift bot needs `ok-to-test` to allow non member PRs to run the tests.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants