-
Notifications
You must be signed in to change notification settings - Fork 178
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
Disabling the 'Deploy model' button if NIM is disabled #3600
base: main
Are you sure you want to change the base?
Disabling the 'Deploy model' button if NIM is disabled #3600
Conversation
Signed-off-by: Olga Lavtar <[email protected]>
Signed-off-by: Olga Lavtar <[email protected]>
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: 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 |
Hi @olavtar. 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 Once the patch is verified, the new status will be reflected by the 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. |
Signed-off-by: Olga Lavtar <[email protected]>
/ok-to-test |
const isNIMModelServingAvailable = useIsAreaAvailable(SupportedArea.NIM_MODEL).status; | ||
|
||
useEffect(() => { | ||
const checkNIMServingRuntime = async () => { | ||
const isNIMRuntimeAvailable = await isNIMServingRuntimeTemplateAvailable(dashboardNamespace); | ||
setIsNIMAvailable(isNIMModelServingAvailable && isNIMRuntimeAvailable); | ||
}; | ||
const fetchNIMAvailability = React.useCallback(async () => { | ||
const components = await fetchComponents(false); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you make the fetchNIMAvailability
return early with false
if isNIMModelServingAvailable
is false
? This way it will avoid the following API calls when we already know nim is not available
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated
…delServingAvailable is false Signed-off-by: Olga Lavtar <[email protected]>
https://issues.redhat.com/browse/NVPE-66
https://issues.redhat.com/browse/NVPE-34
Description
If NIM is disabled, previously deployed projects are prevented from re-deploying a NIM model by disabling the 'Deploy model' button on various screens.
How Has This Been Tested?
Tested locally and verified various scenarios:
Test Impact
Cypress tests were modified to accommodate.
Request review criteria:
Self checklist (all need to be checked):
If you have UI changes:
After the PR is posted & before it merges:
main