-
Notifications
You must be signed in to change notification settings - Fork 13
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
6th step - remove output key from execution #975
6th step - remove output key from execution #975
Conversation
This pull request has been mentioned on MESG Community. There might be relevant details there: https://forum.mesg.com/t/simplification-of-the-tasks-output/265/6 |
@@ -69,5 +70,8 @@ func (s *Server) ListenTask(request *serviceapi.ListenTaskRequest, stream servic | |||
|
|||
// SubmitResult submits results of an execution. | |||
func (s *Server) SubmitResult(context context.Context, request *serviceapi.SubmitResultRequest) (*serviceapi.SubmitResultReply, error) { | |||
return &serviceapi.SubmitResultReply{}, s.api.SubmitResult(request.ExecutionID, request.OutputKey, []byte(request.OutputData)) | |||
if request.OutputKey == "error" { | |||
return &serviceapi.SubmitResultReply{}, s.api.SubmitResult(request.ExecutionID, nil, errors.New(request.OutputData)) |
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.
should be request.OutputData.message
, the error here will look like
"{message: 'xxx'}"
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.
Not everyone supposes to put an error in the message. Here error needs to be just string. If you want to extend it somehow that's fine, but at the base is a string.
Why do we need to force message here? what's the point if we can have just plain text?
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.
don't have the result when I execute a task that returns an error
There is the bug in core :
So the ListenResult won't listen the exeuction that failed, it's not related to this PR |
Here the execution changes state so we should have it on the stream, this is a regression engine/interface/grpc/core/core.go Line 180 in 60540cf
but ok this can be fixed in parallel but needs to be fixed |
This pull request has been mentioned on MESG Community. There might be relevant details there: https://forum.mesg.com/t/simplification-of-the-tasks-output/265/7 |
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.
I guess all issues on this one are fixed in the next ones, @krhubert if it's right you can merge this one
No description provided.