Conversation
|
Claude finished @rexxars's task in 2m 31s —— View job Code Review
When
query: {appType: 'coreApp', organizationId: organizationId!},The non-null assertion suppresses the TypeScript error but if the internal overload is called without
After a successful undeploy, the reminder logic at line 69–77 checks Not a bug, but the coverage drop (−1.8%) is likely from the post-undeploy reminder path not being covered for the interactive selection case. |
Coverage Delta
Comparing 2 changed files against main @ Overall Coverage
|
- Wrap deleteUserApplication in try/catch so spinner fails properly on error - Add test for delete API failure (500 response) - Add missing 'Remember to remove' assertion on prioritizes deployment.appId test Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Narrow `err` to `Error | string` in promptForApplication catch block - Distinguish null (API error) from empty array in getUserApplications - Fix misleading "not been assigned" message when configured host doesn't exist - Add test for app listing API failure Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Remove explicit {exit: 1} from app listing error to default to 2,
matching the studio path behavior
- Add test for studio listing API failure in interactive mode
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Remove double error handling in promptForApplication by delegating directly to promptForApp/promptForStudio. Add try/catch in both prompt methods for consistent error handling and fix variable naming bug. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
4c751af to
7f352e7
Compare
- Use spin.info() instead of spin.fail() for empty app/studio lists since an empty result is not an error - Remove error swallowing in getUserApplications for coreApp so server errors propagate with their original message - Fix implementation return type to match overloads (no more | null) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Use getAppId() for the "remember to remove" check so it also triggers for the deprecated app.id config path - Remove redundant this.parse() call since init() already populates flags - Add explicit assertions to the rejection-after-selection test - Add test for deprecated app.id showing the reminder message Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Show the right config key in the reminder message depending on whether
deployment.appId or the deprecated app.id is set
- Remove unreachable {default: 'true'} fallback in getUserApplication
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Fix type error from removing ternary in getUserApplication by using proper branching for appHost - Remove dead isSdkApp URI fallback (appId is required by the type) - Use spin.info() consistently for missing config (orgId, projectId) instead of spin.fail() + this.log() - Add test for studio deployment.appId with missing projectId Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Description
Not urgent, new behavior.
Sort of annoying that if you deploy a studio/app and don't remember/see to put the appId into your CLI config,
undeployjust… doesn't work. Now, if there's noappIdspecified, we allow the user to select from a list of apps. If it detects that you're in an app folder, it will give you app choices. If you're in a studio folder, it will give you studios.Prompts before actually undeploying.
What to review
Do the flows make sense?
Flowchart:
Testing
Added new tests for the new behavior