The Dart language implementation of gRPC.
Go to file
Vyacheslav Egorov 7cced9282a
Fix compilation with DDC (#516)
b272632450 exposed client certificate through 
`X509Certificate? get clientCertificate;` getter on `ServiceCall` class. This broke 
compilation of `grpc_web` code using DDC, but not dart2js. Turns out that dart2js is 
happy to compile any code using `dart:io` (though the result will not run if you try
to use any of those APIs), but DDC rejects such code eagerly. `package:test` runs 
tests through `dart2js` so DDC breakage was not really caught by CI. 

Unfortunately this discrepancy between DDC and dart2js puts us in some really weird 
spot: most of our tests are platform independent, but most of those tests also 
pull in `dart:io` through transitive dependencies.

This commit is the most minimal change we could make to allow the code compile both 
on the Web and natively. 

A proper fix should be to go through tests one-by-one and make sure that those that
need to run on the Web don't import `dart:io`, but we don't have time to do that 
right now. 

This commit also adds a smoke test to the CI to verify that `grpc_web` example 
builds with DDC.
2021-08-16 14:52:36 +02:00
.github Fix compilation with DDC (#516) 2021-08-16 14:52:36 +02:00
example Fix CI 2021-08-10 11:04:11 +02:00
interop Fix interop tests (#513) 2021-08-10 11:15:39 +02:00
lib Fix compilation with DDC (#516) 2021-08-16 14:52:36 +02:00
test Add custom trailers to GrpcError (#493) 2021-08-10 11:53:09 +02:00
tool Cleanups (#398) 2020-11-12 11:36:59 +01:00
.gitignore Add decoded grpc-status-details-bin details to GrpcError (#349) 2020-10-27 17:07:58 +01:00
AUTHORS allows async interceptors (#120) 2018-09-18 08:17:39 +02:00
CHANGELOG.md Fix compilation with DDC (#516) 2021-08-16 14:52:36 +02:00
CODE-OF-CONDUCT.md Update CODE-OF-CONDUCT.md (#49) 2018-01-19 10:50:18 +01:00
CONTRIBUTING.md Fix for duplicate headers (#397) 2020-11-12 09:51:57 +01:00
LICENSE Change license to Apache to be consistent with other gRPC repos (#47) 2018-01-12 15:14:19 +01:00
MAINTAINERS.md Update MAINTAINERS.md (#234) 2019-08-27 14:37:35 +02:00
README.md Add support for unix domain sockets (#327) 2020-11-11 15:43:05 +01:00
SECURITY.md Create SECURITY.md (#433) 2021-01-26 14:56:10 +01:00
analysis_options.yaml Enable and fix pedantic v1.9 lints (#445) 2021-02-01 09:12:26 +01:00
build.yaml grpc-web support (#191) 2019-06-17 13:31:07 +02:00
pubspec.yaml Fix compilation with DDC (#516) 2021-08-16 14:52:36 +02:00

README.md

The Dart implementation of gRPC: A high performance, open source, general RPC framework that puts mobile and HTTP/2 first.

CI status pub package

Learn more

For complete documentation, see Dart gRPC.

Supported platforms

Note: grpc-web is supported by package:grpc/grpc_web.dart. UDS-unix domain socket is supported with sdk version >= 2.8.0.

Contributing

If you experience problems or have feature requests, open an issue.

Note that we have limited bandwidth to accept PRs, and that all PRs require signing the EasyCLA.