We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
func (c *CategoryService) CreateCategoryStream(stream pb.CategoryService_CreateCategoryStreamServer) error { categories := &pb.CategoryList{} for { category, err := stream.Recv() log.Println(category) if err == io.EOF { return stream.SendAndClose(categories) } if err != nil { return err } categoryResult, err := c.CategoryDB.Create(category.Name, category.Description) if err != nil { return err } categories.Categories = append(categories.Categories, &pb.Category{ Id: categoryResult.ID, Name: categoryResult.Name, Description: categoryResult.Description, }) // log.Println(categories) } }
protoc
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I have the following func below. After add the category I pressed Ctrl+D, but it didn't raise the error io.EOF to trigger stream.SendAndClose
To reproduce
Expected behavior
Screenshots
Environment
protoc
version: libprotoc 3.12.4protoc
plugin version (if you are using):Additional context
The text was updated successfully, but these errors were encountered: