-
Notifications
You must be signed in to change notification settings - Fork 730
fix(smus): update space before creating new app if space setting is changed #8170
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
Conversation
|
⏳ I'm reviewing this pull request for security vulnerabilities and code quality issues. I'll provide an update when I'm done |
|
|
✅ I finished the code review, and didn't find any security or code quality issues. |
| const instanceTypeChanged = requestedResourceSpec?.InstanceType !== instanceType | ||
|
|
||
| if (needsRemoteAccess || instanceTypeChanged) { | ||
| const settingsPropName = appType === 'JupyterLab' ? 'JupyterLabAppSettings' : 'CodeEditorAppSettings' |
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.
Can we make these checks case insensitive just to be safe? Just lowercase everything and then check. And while it works now to do an either condition, it will break if a new AppType gets added for example. So lets just keep a mapping of JuypyterLab: JupyterLabAppSettings, CodeEditor : CodeEditorAppSettings
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.
It is fixed. Used a map for App specific setting name, and used AppType for app types.
| DefaultResourceSpec: { | ||
| InstanceType: instanceType, | ||
| }, |
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.
If there were other values in DefaultResourceSpec already (eg - ImageArn), would this overwrite it or leave it as is and only update instance type?
If it overwrites, that is not the behavior we want, we should only be updating instance type and not the other params.
|
Ignore this and create a new PR |
Problem
Solution
feature/xbranches will not be squash-merged at release time.