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

Merge package:stream_channel #1266

Open
wants to merge 149 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
149 commits
Select commit Hold shift + click to select a range
d56a057
Initial commit.
nex3 Jan 20, 2016
d0b0d2d
Add codereview.settings.
nex3 Jan 20, 2016
3ee20be
Add StreamChannel and MultiChannel.
nex3 Jan 21, 2016
31deaca
Add a DelegatingStreamChannel class.
nex3 Jan 21, 2016
9eea776
Add clearer rules for implementations.
nex3 Jan 21, 2016
58ce9f4
Fix DelegatingStreamChannel.
nex3 Jan 25, 2016
8c8923d
Add a StreamChannelCompleter class.
nex3 Jan 26, 2016
6c2fd24
Add an IsolateChannel class.
nex3 Jan 26, 2016
1a2eb42
Add StreamChannel.transform().
nex3 Jan 26, 2016
8a594ea
Add StreamChannelTransformer.
nex3 Jan 27, 2016
83b986e
Add IsolateChannel.connect* constructors.
nex3 Jan 27, 2016
58a4730
Add a document-by-document JSON transformer.
nex3 Jan 28, 2016
27f7f49
Release version 1.0.0.
nex3 Jan 28, 2016
b2d2178
Fix the MultiChannel constructor.
nex3 Jan 28, 2016
7c16f93
Be more explicit about JSON error handling.
nex3 Feb 1, 2016
ad40640
Add support for stream- and sink-specific changes.
nex3 Feb 1, 2016
a251a33
Fix inverted generic parameters.
nex3 Feb 2, 2016
d0af7ea
Add StreamChannel.withGuarantees and StreamChannelController.
nex3 Feb 4, 2016
8bd8af5
Provide more error-handling customization.
nex3 Feb 5, 2016
f581028
Make IsolateChannel use StreamChannelCompleter.
nex3 Feb 9, 2016
ed797d0
Add a Disconnector class.
nex3 Feb 9, 2016
0f4b747
Make IsolateChannel's controllers synchronous.
nex3 Feb 10, 2016
2ff097b
Make MultiChannel follow the stream channel rules.
nex3 Feb 10, 2016
05da8f9
Fix unused imports
srawlins Mar 9, 2016
b171df4
Merge pull request dart-lang/stream_channel#2 from srawlins/fix-unuse…
nex3 Mar 10, 2016
d58d636
Fix all strong-mode errors and warnings.
nex3 May 10, 2016
cafec58
Bump the version to 1.3.2.
nex3 May 10, 2016
0029c28
Add type-coercion functions.
nex3 May 10, 2016
29a1b02
Add StreamChannel.withCloseGuarantee.
nex3 Jun 6, 2016
e39e092
Bump the pubspec version to 1.5.0.
nex3 Jun 6, 2016
a35416e
Fix transformer tests.
nex3 Jun 6, 2016
6a99277
Return a future from Disconnector.disconnect(). (dart-lang/stream_cha…
nex3 Jan 19, 2017
963bab0
Fix the type args for StreamChannel.transform(). (dart-lang/stream_ch…
nex3 Jan 25, 2017
48080d0
Update comment style generic syntax
keertip Jul 26, 2017
6f2269b
Rename analysis options
kevmoo Jul 26, 2017
398407e
dartfmt
kevmoo Jul 26, 2017
045a8c6
Stop using deprecated pkg/test expect methods
kevmoo Jul 26, 2017
d63ae51
Remove unused var
kevmoo Jul 26, 2017
9744679
enable travis-ci
kevmoo Jul 26, 2017
2a9b499
Remove -dev.infinity in SDK upper constraint
kevmoo Sep 19, 2017
6cac036
Declare support for async 2.0.0 (dart-lang/stream_channel#10)
nex3 Sep 22, 2017
dc0bf36
Use pumpEventQueue() from test (dart-lang/stream_channel#12)
nex3 Nov 20, 2017
677ee9a
prep for release
grouma Dec 19, 2017
7a7187c
Merge pull request dart-lang/stream_channel#13 from dart-lang/prep-fo…
grouma Dec 19, 2017
4c5a9c9
Stop testing on Dartium (dart-lang/stream_channel#15)
kevmoo Feb 20, 2018
7a53d88
Fix a race condition (dart-lang/stream_channel#16)
nex3 Feb 27, 2018
7b0392b
make sure the inner sink is properly typed in JsonDocumentTransformer…
jakemac53 Apr 16, 2018
4e38542
update pubspec/changelog
jakemac53 Apr 16, 2018
3b092fb
fix pubspec version to match changelog
jakemac53 Apr 16, 2018
c4dcc8d
code review updates
jakemac53 Apr 16, 2018
98126cf
Merge pull request dart-lang/stream_channel#18 from dart-lang/json-do…
jakemac53 Apr 16, 2018
278de14
Upgrade some hints to errors (dart-lang/stream_channel#19)
natebosch Apr 17, 2018
5194728
fix tests for dart 2
jakemac53 May 1, 2018
b32ad83
update changelog/pubspec
jakemac53 May 1, 2018
99325e8
fix some stream channel tests
jakemac53 May 1, 2018
12505ab
Merge pull request dart-lang/stream_channel#21 from dart-lang/fix-dar…
jakemac53 May 1, 2018
509e736
Fix a remaining Dart 2 issue (dart-lang/stream_channel#23)
nex3 May 2, 2018
9a19919
Stop testing IsolateChannel on browsers (dart-lang/stream_channel#24)
nex3 May 20, 2018
dbe4ec1
Remove upper case constants (dart-lang/stream_channel#17)
lrhn Jun 1, 2018
533026d
Allow a type on MultiChannel (dart-lang/stream_channel#26)
natebosch Jun 8, 2018
58810c9
Drop dependency on StackTrace (dart-lang/stream_channel#27)
natebosch Jun 8, 2018
ff1febd
Fix doc comment references (dart-lang/stream_channel#28)
natebosch Jun 8, 2018
b0dc302
Enable prefer_typing_unitialized_varables lint (dart-lang/stream_chan…
natebosch Jun 12, 2018
338ee53
Cast streams to correct types in IsolateChannel (dart-lang/stream_cha…
natebosch Jun 12, 2018
19ba981
Allow SDK versions <3.0.0 (dart-lang/stream_channel#32)
chalin Jul 18, 2018
3191148
Remove optional new/const (dart-lang/stream_channel#37)
natebosch Mar 26, 2019
b86f7a0
Add separate import for `IsolateChannel` (dart-lang/stream_channel#40)
natebosch Mar 26, 2019
c3babdc
Enforce override annotations (dart-lang/stream_channel#42)
natebosch Mar 27, 2019
db09351
Move isolate_channel to it's own import (dart-lang/stream_channel#39)
natebosch Mar 28, 2019
662bcb4
Hide JsonDocumentTransformer (dart-lang/stream_channel#43)
natebosch Mar 28, 2019
7c910ba
Remove StreamChannelTransformer.typed (dart-lang/stream_channel#44)
natebosch Mar 28, 2019
e4af414
Change all bare Future to Future<void> (dart-lang/stream_channel#45)
natebosch Mar 28, 2019
56ef31e
Use pedantic lints
srawlins Jul 23, 2019
d5c4743
Merge pull request dart-lang/stream_channel#46 from srawlins/pedantic
srawlins Jul 23, 2019
3359284
Remove unneeded codereview.settings
kevmoo Jul 25, 2019
d77f047
Fix outdated URLs
kevmoo Jul 25, 2019
077574a
Add missing dartfmt --fix lint
kevmoo Jul 25, 2019
4d81dea
Test on oldest supported Dart SDK
kevmoo Jul 25, 2019
a3da738
pubspec: Make the description a bit longer
kevmoo Jul 25, 2019
f1838d9
Require Dart 2.2 – because pkg:pedantic
kevmoo Jul 25, 2019
69ec2c6
Fix newly enforce package:pedantic lints (dart-lang/stream_channel#48)
natebosch Dec 5, 2019
364b71f
Fix implicit casts (dart-lang/stream_channel#49)
natebosch Jan 14, 2020
75f49ee
Drop usages of Delegating*.typed (dart-lang/stream_channel#50)
natebosch Jan 14, 2020
8358111
Close send channel in test (dart-lang/stream_channel#54)
natebosch Mar 18, 2020
eb109ae
Rewrite doc comment to refer to TypeError (dart-lang/stream_channel#57)
natebosch Apr 2, 2020
1f61afe
Merge the null_safety branch into master (dart-lang/stream_channel#60)
jakemac53 Jul 16, 2020
e61fb5e
update for the 2.10 dev sdk (dart-lang/stream_channel#61)
jakemac53 Jul 22, 2020
83c6c48
Delete .test_config
kevmoo Jul 28, 2020
729a4c6
Update Travis-CI to use dev channel (dart-lang/stream_channel#62)
kevmoo Jul 28, 2020
dfc6fd7
Remove the author section from pubspec (dart-lang/stream_channel#63)
natebosch Jul 30, 2020
bb72478
Prepare for the 2.11 dev SDKs (dart-lang/stream_channel#64)
natebosch Sep 22, 2020
18d7aa8
Remove unused dart:async import
srawlins Oct 20, 2020
e8e0eb1
Merge pull request dart-lang/stream_channel#65 from dart-lang/srawlin…
srawlins Oct 20, 2020
85fcb60
allow the 2.12 prerelease sdks (dart-lang/stream_channel#66)
jakemac53 Oct 23, 2020
e8efb13
Bump SDK constraints for pub (dart-lang/stream_channel#67)
natebosch Nov 3, 2020
87fb3b0
remove redundant experiment
pq Nov 11, 2020
b0cd8e6
Merge pull request dart-lang/stream_channel#68 from dart-lang/pq-patch-1
pq Nov 11, 2020
f2dcd31
Remove unnecessary import
srawlins Dec 30, 2020
3d270a0
Merge pull request dart-lang/stream_channel#69 from srawlins/unn-import
srawlins Jan 7, 2021
85a211c
Migrate to GitHub Actions (dart-lang/stream_channel#70)
athomas Jan 20, 2021
8fff9b5
Revert "Remove unnecessary import" (dart-lang/stream_channel#71)
jakemac53 Feb 2, 2021
f114ba8
Prepare to publish for stable null safety (dart-lang/stream_channel#72)
natebosch Feb 2, 2021
2cb7547
Update LICENSE
franklinyow Mar 31, 2021
ed6ab45
Merge pull request dart-lang/stream_channel#73 from dart-lang/frankli…
franklinyow Mar 31, 2021
242cca3
Remove unneeded imports (dart-lang/stream_channel#74)
kevmoo May 24, 2021
da7d979
add dependabot
kevmoo Jun 5, 2021
2c5c7e9
Bump dart-lang/setup-dart from 0.3 to 1 (dart-lang/stream_channel#75)
dependabot[bot] Jun 5, 2021
1996879
Migrate to pkg:lints recommended (dart-lang/stream_channel#76)
kevmoo Nov 11, 2021
8ebfdae
Bump actions/checkout from 2 to 3 (dart-lang/stream_channel#78)
dependabot[bot] Mar 2, 2022
3ec468e
populate the pubspec repository field
devoncarew May 3, 2022
e178b20
Merge pull request dart-lang/stream_channel#79 from dart-lang/reposit…
devoncarew May 3, 2022
1183418
Handle non-int multichannel message IDs (dart-lang/stream_channel#80)
natebosch Sep 20, 2022
5ad2e2d
Prepare to publish (dart-lang/stream_channel#81)
natebosch Sep 21, 2022
34bf358
blast_repo fixes (dart-lang/stream_channel#82)
kevmoo Nov 10, 2022
d31e1c8
Bump actions/checkout from 3.1.0 to 3.2.0 (dart-lang/stream_channel#83)
dependabot[bot] Jan 3, 2023
1e06bc9
Migrate from no-implicit-casts to strict-casts (dart-lang/stream_chan…
srawlins Jan 10, 2023
4a85141
Bump actions/checkout from 3.2.0 to 3.3.0 (dart-lang/stream_channel#86)
dependabot[bot] Feb 1, 2023
b4ae743
Bump dart-lang/setup-dart from 1.3 to 1.4 (dart-lang/stream_channel#85)
dependabot[bot] Feb 1, 2023
865feb6
move to pkg:dart_flutter_team_lints lints, fix code, bump min SDK (da…
kevmoo Feb 28, 2023
a831fcb
Bump actions/checkout from 3.3.0 to 3.5.0 (dart-lang/stream_channel#89)
dependabot[bot] Apr 3, 2023
871b223
Bump dart-lang/setup-dart from 1.4.0 to 1.5.0 (dart-lang/stream_chann…
dependabot[bot] Apr 3, 2023
73f5b89
Add example/example.dart (dart-lang/stream_channel#52)
thosakwe Apr 11, 2023
28c22df
Bump actions/checkout from 3.5.0 to 3.5.2 (dart-lang/stream_channel#90)
dependabot[bot] May 8, 2023
eedb369
blast_repo fixes (dart-lang/stream_channel#91)
devoncarew May 19, 2023
67ed073
Fix a race condition in IsolateChannel.connectReceive() (dart-lang/st…
nex3 Jun 20, 2023
ce71194
Bump actions/checkout from 3.5.2 to 3.5.3 (dart-lang/stream_channel#93)
dependabot[bot] Jul 1, 2023
e98c5ba
Bump actions/checkout from 3.5.3 to 3.6.0 (dart-lang/stream_channel#94)
dependabot[bot] Sep 1, 2023
d00914a
Bump actions/checkout from 3.6.0 to 4.1.0 (dart-lang/stream_channel#95)
dependabot[bot] Oct 1, 2023
de516dc
Bump dart-lang/setup-dart from 1.5.0 to 1.5.1 (dart-lang/stream_chann…
dependabot[bot] Oct 3, 2023
ef68439
Bump actions/checkout from 4.1.0 to 4.1.1 (dart-lang/stream_channel#97)
dependabot[bot] Nov 1, 2023
913e78c
Bump dart-lang/setup-dart from 1.5.1 to 1.6.0 (dart-lang/stream_chann…
dependabot[bot] Nov 1, 2023
1cf10a4
Bump dart-lang/setup-dart from 1.6.0 to 1.6.2 (dart-lang/stream_chann…
dependabot[bot] Feb 1, 2024
c7eef23
blast_repo fixes (dart-lang/stream_channel#101)
kevmoo Feb 17, 2024
45fbe10
Require Dart 3.3, update and fix lints (dart-lang/stream_channel#100)
kevmoo Feb 17, 2024
81110f1
Bump actions/checkout from 4.1.1 to 4.1.2 (dart-lang/stream_channel#102)
dependabot[bot] Apr 1, 2024
9992ce8
Bump dart-lang/setup-dart from 1.6.2 to 1.6.4 (dart-lang/stream_chann…
dependabot[bot] May 1, 2024
00f8ce7
Bump actions/checkout from 4.1.2 to 4.1.4 (dart-lang/stream_channel#104)
dependabot[bot] May 1, 2024
9f26b26
blast_repo fixes (dart-lang/stream_channel#105)
devoncarew May 13, 2024
cc95d86
Bump actions/checkout from 4.1.4 to 4.1.5 in the github-actions group…
dependabot[bot] May 13, 2024
3c38e1f
Bump actions/checkout from 4.1.5 to 4.1.6 in the github-actions group…
dependabot[bot] Jun 1, 2024
5c400a8
bump lints (dart-lang/stream_channel#108)
kevmoo Jun 24, 2024
2d967e9
Bump the github-actions group with 2 updates (dart-lang/stream_channe…
dependabot[bot] Jul 1, 2024
c49c410
Fix some trivial doc comment lints (dart-lang/stream_channel#110)
kevmoo Jul 29, 2024
b820aeb
Bump actions/checkout from 4.1.7 to 4.2.0 in the github-actions group…
dependabot[bot] Oct 1, 2024
ae5aad4
Bump actions/checkout from 4.2.0 to 4.2.2 in the github-actions group…
dependabot[bot] Nov 1, 2024
7808a88
Bump dart-lang/setup-dart in the github-actions group (dart-lang/stre…
dependabot[bot] Dec 1, 2024
af4f628
Merge package:stream_channel into the tools monorepo
mosuem Dec 10, 2024
8021ff0
Add issue template and other fixes
mosuem Dec 10, 2024
e66e313
merge fixes
mosuem Dec 10, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .github/ISSUE_TEMPLATE/stream_channel.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
name: "package:stream_channel"
about: "Create a bug or file a feature request against package:stream_channel."
labels: "package:stream_channel"
---
4 changes: 4 additions & 0 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,10 @@
- changed-files:
- any-glob-to-any-file: 'pkgs/source_map_stack_trace/**'

'package:stream_channel':
- changed-files:
- any-glob-to-any-file: 'pkgs/stream_channel/**'

'package:unified_analytics':
- changed-files:
- any-glob-to-any-file: 'pkgs/unified_analytics/**'
74 changes: 74 additions & 0 deletions .github/workflows/stream_channel.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
name: package:stream_channel

on:
# Run on PRs and pushes to the default branch.
push:
branches: [ main ]
paths:
- '.github/workflows/stream_channel.yaml'
- 'pkgs/stream_channel/**'
pull_request:
branches: [ main ]
paths:
- '.github/workflows/stream_channel.yaml'
- 'pkgs/stream_channel/**'
schedule:
- cron: "0 0 * * 0"

env:
PUB_ENVIRONMENT: bot.github

defaults:
run:
working-directory: pkgs/stream_channel/

jobs:
# Check code formatting and static analysis on a single OS (linux)
# against Dart dev.
analyze:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
sdk: [dev]
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
- uses: dart-lang/setup-dart@e630b99d28a3b71860378cafdc2a067c71107f94
with:
sdk: ${{ matrix.sdk }}
- id: install
name: Install dependencies
run: dart pub get
- name: Check formatting
run: dart format --output=none --set-exit-if-changed .
if: always() && steps.install.outcome == 'success'
- name: Analyze code
run: dart analyze --fatal-infos
if: always() && steps.install.outcome == 'success'

# Run tests on a matrix consisting of two dimensions:
# 1. OS: ubuntu-latest, (macos-latest, windows-latest)
# 2. release channel: dev
test:
needs: analyze
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
# Add macos-latest and/or windows-latest if relevant for this package.
os: [ubuntu-latest]
sdk: [3.3, dev]
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
- uses: dart-lang/setup-dart@e630b99d28a3b71860378cafdc2a067c71107f94
with:
sdk: ${{ matrix.sdk }}
- id: install
name: Install dependencies
run: dart pub get
- name: Run VM tests
run: dart test --platform vm
if: always() && steps.install.outcome == 'success'
- name: Run Chrome tests
run: dart test --platform chrome
if: always() && steps.install.outcome == 'success'
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ don't naturally belong to other topic monorepos (like
| [mime](pkgs/mime/) | Utilities for handling media (MIME) types, including determining a type from a file extension and file contents. | [![package issues](https://img.shields.io/badge/package:mime-4774bc)](https://github.com/dart-lang/tools/issues?q=is%3Aissue+is%3Aopen+label%3Apackage%3Amime) | [![pub package](https://img.shields.io/pub/v/mime.svg)](https://pub.dev/packages/mime) |
| [oauth2](pkgs/oauth2/) | A client library for authenticating with a remote service via OAuth2 on behalf of a user, and making authorized HTTP requests with the user's OAuth2 credentials. | [![package issues](https://img.shields.io/badge/package:oauth2-4774bc)](https://github.com/dart-lang/tools/issues?q=is%3Aissue+is%3Aopen+label%3Apackage%3Aoauth2) | [![pub package](https://img.shields.io/pub/v/oauth2.svg)](https://pub.dev/packages/oauth2) |
| [source_map_stack_trace](pkgs/source_map_stack_trace/) | A package for applying source maps to stack traces. | [![package issues](https://img.shields.io/badge/package:source_map_stack_trace-4774bc)](https://github.com/dart-lang/tools/issues?q=is%3Aissue+is%3Aopen+label%3Apackage%3Asource_map_stack_trace) | [![pub package](https://img.shields.io/pub/v/source_map_stack_trace.svg)](https://pub.dev/packages/source_map_stack_trace) |
| [stream_channel](pkgs/stream_channel/) | An abstraction for two-way communication channels based on the Dart Stream class. | [![package issues](https://img.shields.io/badge/package:stream_channel-4774bc)](https://github.com/dart-lang/tools/issues?q=is%3Aissue+is%3Aopen+label%3Apackage%3Astream_channel) | [![pub package](https://img.shields.io/pub/v/stream_channel.svg)](https://pub.dev/packages/stream_channel) |
| [unified_analytics](pkgs/unified_analytics/) | A package for logging analytics for all Dart and Flutter related tooling to Google Analytics. | [![package issues](https://img.shields.io/badge/package:unified_analytics-4774bc)](https://github.com/dart-lang/tools/issues?q=is%3Aissue+is%3Aopen+label%3Apackage%3Aunified_analytics) | [![pub package](https://img.shields.io/pub/v/unified_analytics.svg)](https://pub.dev/packages/unified_analytics) |

## Publishing automation
Expand Down
10 changes: 10 additions & 0 deletions pkgs/stream_channel/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
.buildlog
.dart_tool/
.DS_Store
.idea
.pub/
.settings/
build/
packages
.packages
pubspec.lock
6 changes: 6 additions & 0 deletions pkgs/stream_channel/AUTHORS
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Below is a list of people and organizations that have contributed
# to the project. Names should be added to the list like so:
#
# Name/Organization <email address>

Google Inc.
158 changes: 158 additions & 0 deletions pkgs/stream_channel/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,158 @@
## 2.1.3

* Require Dart 3.3
* Move to `dart-lang/tools` monorepo.

## 2.1.2

* Require Dart 2.19
* Add an example.
* Fix a race condition in `IsolateChannel.connectReceive()` where the channel
could hang forever if its sink was closed before the connection was established.

## 2.1.1

* Require Dart 2.14
* Populate the pubspec `repository` field.
* Handle multichannel messages where the ID element is a `double` at runtime
instead of an `int`. When reading an array with `dart2wasm` numbers within the
array are parsed as `double`.

## 2.1.0

* Stable release for null safety.

## 2.0.0

**Breaking changes**

* `IsolateChannel` requires a separate import
`package:stram_channel/isolate_channel.dart`.
`package:stream_channel/stream_channel.dart` will now not trigger any platform
concerns due to importing `dart:isolate`.
* Remove `JsonDocumentTransformer` class. The `jsonDocument` top level is still
available.
* Remove `StreamChannelTransformer.typed`. Use `.cast` on the transformed
channel instead.
* Change `Future<dynamic>` returns to `Future<void>`.

## 1.7.0

* Make `IsolateChannel` available through
`package:stream_channel/isolate_channel.dart`. This will be the required
import in the next release.
* Require `2.0.0` or newer SDK.
* Internal style changes.

## 1.6.8

* Set max SDK version to `<3.0.0`, and adjust other dependencies.

## 1.6.7+1

* Fix Dart 2 runtime types in `IsolateChannel`.

## 1.6.7

* Update SDK version to 2.0.0-dev.17.0.
* Add a type argument to `MultiChannel`.

## 1.6.6

* Fix a Dart 2 issue with inner stream transformation in `GuaranteeChannel`.

* Fix a Dart 2 issue with `StreamChannelTransformer.fromCodec()`.

## 1.6.5

* Fix an issue with `JsonDocumentTransformer.bind` where it created an internal
stream channel which didn't get a properly inferred type for its `sink`.

## 1.6.4

* Fix a race condition in `MultiChannel` where messages from a remote virtual
channel could get dropped if the corresponding local channel wasn't registered
quickly enough.

## 1.6.3

* Use `pumpEventQueue()` from test.

## 1.6.2

* Declare support for `async` 2.0.0.

## 1.6.1

* Fix the type of `StreamChannel.transform()`. This previously inverted the
generic parameters, so it only really worked with transformers where both
generic types were identical.

## 1.6.0

* `Disconnector.disconnect()` now returns a future that completes when all the
inner `StreamSink.close()` futures have completed.

## 1.5.0

* Add `new StreamChannel.withCloseGuarantee()` to provide the specific guarantee
that closing the sink causes the stream to close before it emits any more
events. This is the only guarantee that isn't automatically preserved when
transforming a channel.

* `StreamChannelTransformer`s provided by the `stream_channel` package now
properly provide the guarantee that closing the sink causes the stream to
close before it emits any more events

## 1.4.0

* Add `StreamChannel.cast()`, which soundly coerces the generic type of a
channel.

* Add `StreamChannelTransformer.typed()`, which soundly coerces the generic type
of a transformer.

## 1.3.2

* Fix all strong-mode errors and warnings.

## 1.3.1

* Make `IsolateChannel` slightly more efficient.

* Make `MultiChannel` follow the stream channel rules.

## 1.3.0

* Add `Disconnector`, a transformer that allows the caller to disconnect the
transformed channel.

## 1.2.0

* Add `new StreamChannel.withGuarantees()`, which creates a channel with extra
wrapping to ensure that it obeys the stream channel guarantees.

* Add `StreamChannelController`, which can be used to create custom
`StreamChannel` objects.

## 1.1.1

* Fix the type annotation for `StreamChannel.transform()`'s parameter.

## 1.1.0

* Add `StreamChannel.transformStream()`, `StreamChannel.transformSink()`,
`StreamChannel.changeStream()`, and `StreamChannel.changeSink()` to support
changing only the stream or only the sink of a channel.

* Be more explicit about `JsonDocumentTransformer`'s error-handling behavior.

## 1.0.1

* Fix `MultiChannel`'s constructor to take a `StreamChannel`. This is
technically a breaking change, but since 1.0.0 was only released an hour ago,
we're treating it as a bug fix.

## 1.0.0

* Initial version
27 changes: 27 additions & 0 deletions pkgs/stream_channel/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
Copyright 2015, the Dart project authors.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:

* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above
copyright notice, this list of conditions and the following
disclaimer in the documentation and/or other materials provided
with the distribution.
* Neither the name of Google LLC nor the names of its
contributors may be used to endorse or promote products derived
from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
20 changes: 20 additions & 0 deletions pkgs/stream_channel/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
[![Build Status](https://github.com/dart-lang/tools/actions/workflows/stream_channel.yaml/badge.svg)](https://github.com/dart-lang/tools/actions/workflows/stream_channel.yaml)
[![pub package](https://img.shields.io/pub/v/stream_channel.svg)](https://pub.dev/packages/stream_channel)
[![package publisher](https://img.shields.io/pub/publisher/stream_channel.svg)](https://pub.dev/packages/stream_channel/publisher)

This package exposes the `StreamChannel` interface, which represents a two-way
communication channel. Each `StreamChannel` exposes a `Stream` for receiving
data and a `StreamSink` for sending it.

`StreamChannel` helps abstract communication logic away from the underlying
protocol. For example, the [`test`][test] package re-uses its test suite
communication protocol for both WebSocket connections to browser suites and
Isolate connections to VM tests.

[test]: https://pub.dev/packages/test

This package also contains utilities for dealing with `StreamChannel`s and with
two-way communications in general. For documentation of these utilities, see
[the API docs][api].

[api]: https://pub.dev/documentation/stream_channel/latest/
5 changes: 5 additions & 0 deletions pkgs/stream_channel/analysis_options.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
include: package:dart_flutter_team_lints/analysis_options.yaml

analyzer:
language:
strict-casts: true
Loading
Loading