keon94 commented on code in PR #4802:
URL:
https://github.com/apache/incubator-devlake/pull/4802#discussion_r1150836787
##########
backend/core/utils/ipc.go:
##########
@@ -260,7 +260,8 @@ func scanErrorPipe(pipe io.ReadCloser, onReceive
func([]byte), outboundChannel c
data := make([]byte, len(src))
copy(data, src)
onReceive(data)
- outboundChannel <- &ProcessResponse{stderr: data}
+ err := errors.Default.New(string(data))
Review Comment:
What's the reason for creating and returning an error here? The "data"
variable here is only going to be single line of text, and is incomplete. If we
return an error here, it is going to prematurely end the IPC. See RunProcess().
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]