-
Notifications
You must be signed in to change notification settings - Fork 460
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
UI: Select namespace from Kubeflow dashboard #982
UI: Select namespace from Kubeflow dashboard #982
Conversation
…w-dashboard-namespace
Experiments monitor Submit yaml Submit experiment by parameters
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.
Looks great, seems like the SDK is used correctly (so it should support realtime update of namespaces, ie. you shouldn't have to navigate to another sub-app and back for the namespace changes to kick in). I've added a few nits. Thanks! 🎉
window.centraldashboard.CentralDashboardEventHandler.init(function (cdeh) { | ||
// Binds a callback that gets invoked anytime the Dashboard's | ||
// namespace is changed | ||
cdeh.onNamespaceSelected = (namespace) => { |
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.
cdeh.onNamespaceSelected = (namespace) => { | |
cdeh.onNamespaceSelected = (namespace) => { |
cdeh.onNamespaceSelected = (namespace) => { | |
cdeh.onNamespaceSelected = onGlobalNamespaceChange |
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.
@avdaredevil What do you mean by this change?
}) | ||
let isRightNamespace = false | ||
for (const [key, value] of Object.entries(action.yaml.split("\n"))) { | ||
let noSpaceLine = value.replace(/\s/g,'') |
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.
let noSpaceLine = value.replace(/\s/g,'') | |
const noSpaceLine = value.replace(/\s/g,'') |
type: generalActions.SUBMIT_YAML_SUCCESS, | ||
}) | ||
let isRightNamespace = false | ||
for (const [key, value] of Object.entries(action.yaml.split("\n"))) { |
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.
Wouldn't the key, in this case, be an index? Since it's not an object, it may make sense to name the vars accordingly?
for (const [key, value] of Object.entries(action.yaml.split("\n"))) { | |
for (const [index, line] of Object.entries(action.yaml.split("\n"))) { |
Sorry if I misinterpreted this line
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.
Yes, it will be the index. I will change it to [index, value]
@avdaredevil Thank you for your review, I will take a look. |
/lgtm Is it ready to merge? |
If @avdaredevil is ok with new changes, yes. |
/lgtm Thanks @andreyvelich! |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: avdaredevil, johnugeorge 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 |
Fixes: #972.
After this PR, when user select namespace from Central Dashboard, in Katib UI user:
Right now, user can see Trial Templates in all namespaces.
/cc @johnugeorge @gaocegege @hougangliu @avdaredevil
Also, in this PR I fixed namespace filter.
This change is