Skip to content
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

Bond.Compiler.CSharp doesn't include *_grpc.cs files #448

Closed
eharshosh opened this issue May 14, 2017 · 4 comments
Closed

Bond.Compiler.CSharp doesn't include *_grpc.cs files #448

eharshosh opened this issue May 14, 2017 · 4 comments

Comments

@eharshosh
Copy link

eharshosh commented May 14, 2017

C# projects won't compile after adding the following directive to the .proj file:

<BondCodegen Include="myService.bond">
  <Options>--grpc</Options>
</BondCodegen>

If i'm not mistaken, Bond.Compiler.CSharp includes *_types.cs file for compilation,
but not *_grpc.cs (after manually including myService_grpc.cs it compiles successfully)

Thanks in advance,
Eitan

@chwarr
Copy link
Member

chwarr commented May 15, 2017

At the moment, this is the expected behavior for the preview release. The targets were not updated to be taught about gRPC. Take a look at the example C# projects. They show how to edit your csproj file to get the build to work.

I'm going to leave this open with the above work around.

@eharshosh
Copy link
Author

Thanks!

@hcoona
Copy link
Contributor

hcoona commented Oct 5, 2017

I made PR #630 for it.

chwarr pushed a commit to chwarr/bond that referenced this issue Oct 21, 2017
Update the MSBuild codegen targets to automatically include the
generated _grpc.cs files if --grpc is passed to gbc.

Fixes microsoft#448
Closes microsoft#630
chwarr added a commit to chwarr/bond that referenced this issue Oct 24, 2017
* The MSBuild codegen targets now detect --structs=false and skip
  automatic compilation of the non-existent `_types.cs` files.
* Added a gRPC example that show how to use a shared type assembly
  between a client and service.

Fixes microsoft#448
Closes microsoft#630
chwarr pushed a commit to chwarr/bond that referenced this issue Oct 24, 2017
* Two cases need to be handeled: $BondOptions contains --grpc for
  no-overridden BondCodegen items, the %BondCodegen.Options contains
  --grpc. Also --grpc=false needs to be handled in both cases.
* Updated the examples ad tests to no longer include the
  generated *_grpc.cs files.

Fixes microsoft#448
Closes microsoft#630
@lalo lalo closed this as completed in a120cd9 Oct 24, 2017
@chwarr
Copy link
Member

chwarr commented Oct 24, 2017

Fixed in version 7.0.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants