mirror of https://github.com/grpc/grpc-dart.git
Avoid completing multiplet times for one error (#454)
Also: * updated SDK constraint to stable * Use latest Dart action install * Test on oldest supported SDK
This commit is contained in:
parent
def1a19339
commit
ee0e7ec351
|
@ -16,12 +16,12 @@ jobs:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
sdk: [dev, beta]
|
sdk: [dev, 2.12.0]
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- uses: cedx/setup-dart@v2
|
- uses: dart-lang/setup-dart@v1.0
|
||||||
with:
|
with:
|
||||||
release-channel: ${{ matrix.sdk }}
|
sdk: ${{ matrix.sdk }}
|
||||||
- name: Report version
|
- name: Report version
|
||||||
run: dart --version
|
run: dart --version
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
|
@ -50,7 +50,7 @@ jobs:
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
os: [ubuntu-latest, macos-latest, windows-latest]
|
os: [ubuntu-latest, macos-latest, windows-latest]
|
||||||
sdk: [dev, beta]
|
sdk: [dev, 2.12.0]
|
||||||
platform: [vm, chrome]
|
platform: [vm, chrome]
|
||||||
exclude:
|
exclude:
|
||||||
# We only run Chrome tests on Linux. No need to run them
|
# We only run Chrome tests on Linux. No need to run them
|
||||||
|
@ -61,9 +61,9 @@ jobs:
|
||||||
platform: chrome
|
platform: chrome
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- uses: cedx/setup-dart@v2
|
- uses: dart-lang/setup-dart@v1.0
|
||||||
with:
|
with:
|
||||||
release-channel: ${{ matrix.sdk }}
|
sdk: ${{ matrix.sdk }}
|
||||||
- name: Report version
|
- name: Report version
|
||||||
run: dart --version
|
run: dart --version
|
||||||
- name: Install envoy
|
- name: Install envoy
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
## 3.0.1-dev
|
||||||
|
|
||||||
## 3.0.0
|
## 3.0.0
|
||||||
|
|
||||||
* Migrate library and tests to null safety.
|
* Migrate library and tests to null safety.
|
||||||
|
|
|
@ -1108,12 +1108,14 @@ class Tester {
|
||||||
}
|
}
|
||||||
call.cancel();
|
call.cancel();
|
||||||
}, onError: (e) {
|
}, onError: (e) {
|
||||||
if (e is! GrpcError) completer.completeError('Unexpected error: $e.');
|
if (e is! GrpcError) {
|
||||||
if (e.code != StatusCode.cancelled) {
|
completer.completeError('Unexpected error: $e.');
|
||||||
|
} else if (e.code != StatusCode.cancelled) {
|
||||||
completer
|
completer
|
||||||
.completeError('Unexpected status code ${e.code}: ${e.message}.');
|
.completeError('Unexpected status code ${e.code}: ${e.message}.');
|
||||||
|
} else {
|
||||||
|
completer.complete(true);
|
||||||
}
|
}
|
||||||
completer.complete(true);
|
|
||||||
}, onDone: () {
|
}, onDone: () {
|
||||||
if (!completer.isCompleted) completer.completeError('Expected error.');
|
if (!completer.isCompleted) completer.completeError('Expected error.');
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
name: grpc
|
name: grpc
|
||||||
description: Dart implementation of gRPC, a high performance, open-source universal RPC framework.
|
description: Dart implementation of gRPC, a high performance, open-source universal RPC framework.
|
||||||
|
|
||||||
version: 3.0.0
|
version: 3.0.1-dev
|
||||||
|
|
||||||
repository: https://github.com/grpc/grpc-dart
|
repository: https://github.com/grpc/grpc-dart
|
||||||
|
|
||||||
environment:
|
environment:
|
||||||
sdk: '>=2.12.0-0 <3.0.0'
|
sdk: '>=2.12.0 <3.0.0'
|
||||||
|
|
||||||
dependencies:
|
dependencies:
|
||||||
archive: ^3.0.0
|
archive: ^3.0.0
|
||||||
|
@ -22,7 +22,7 @@ dependencies:
|
||||||
dev_dependencies:
|
dev_dependencies:
|
||||||
build_runner: ^1.11.0
|
build_runner: ^1.11.0
|
||||||
build_test: ^1.3.4
|
build_test: ^1.3.4
|
||||||
mockito: ^5.0.0-nullsafety.6
|
mockito: ^5.0.0
|
||||||
path: ^1.8.0
|
path: ^1.8.0
|
||||||
test: ^1.16.0
|
test: ^1.16.0
|
||||||
stream_channel: ^2.1.0
|
stream_channel: ^2.1.0
|
||||||
|
|
Loading…
Reference in New Issue