-
Notifications
You must be signed in to change notification settings - Fork 219
Exit non-zero when dapr stop or dapr uninstall fails
#1668
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
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -90,9 +90,9 @@ dapr uninstall --runtime-path <path-to-install-directory> | |
|
|
||
| if err != nil { | ||
| print.FailureStatusEvent(os.Stderr, fmt.Sprintf("Error removing Dapr: %s", err)) | ||
| } else { | ||
| print.SuccessStatusEvent(os.Stdout, "Dapr has been removed successfully") | ||
| os.Exit(1) | ||
| } | ||
| print.SuccessStatusEvent(os.Stdout, "Dapr has been removed successfully") | ||
|
Comment on lines
91
to
+95
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I looked into this - there isn't a clean way to force standalone.Uninstall or kubernetes.Uninstall to fail from the e2e harness today without mocking, so uninstall doesn't have a dedicated exit-code test yet. If there's a preferred fault-injection pattern in this repo I'm happy to add one. |
||
| }, | ||
| } | ||
|
|
||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.
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.
Good call - and CI actually caught this immediately: the existing stop_without_install e2e was asserting the old behavior (error message + exit 0). I flipped that assertion to require a non-zero exit in a369916, so it now doubles as the regression test for this path.