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

Bump version and add changelog entry #38

Merged
merged 6 commits into from
Jan 17, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 2 additions & 2 deletions .github/workflows/bloc_presentation-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,12 @@ jobs:
- name: Set up Dart
uses: dart-lang/setup-dart@v1
with:
sdk: 3.0.0
sdk: 3.6.0

- name: Set up Flutter
uses: subosito/flutter-action@v2
with:
flutter-version: 3.10.0
flutter-version: 3.27.0
cache: true

- name: Publish and release
Expand Down
11 changes: 8 additions & 3 deletions .github/workflows/bloc_presentation-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,17 @@ on:

jobs:
test:
name: Flutter ${{ matrix.version }}
name: Flutter ${{ matrix.flutter.version }}

runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
version: ['3.10.x', '3.13.x']
flutter:
- version: '3.10.x'
- version: '3.13.x'
- version: '3.27.x'
analyze: true

defaults:
run:
Expand All @@ -34,7 +38,7 @@ jobs:
- name: Set up Flutter
uses: subosito/flutter-action@v2
with:
flutter-version: ${{ matrix.version }}
flutter-version: ${{ matrix.flutter.version }}
cache: true

- name: Download pub dependencies
Expand All @@ -44,6 +48,7 @@ jobs:
run: dart format --set-exit-if-changed --output none .

- name: Run analyzer
if: ${{ matrix.flutter.analyze }}
run: flutter analyze --fatal-warnings --fatal-infos

- name: Run tests
Expand Down
4 changes: 4 additions & 0 deletions packages/bloc_presentation/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# 1.1.0

- Bump dependency on `flutter_bloc` to `9.0.0`. (#37, thanks @bobekos)

# 1.0.1

- Removed dependency on `provider`.
Expand Down
2 changes: 1 addition & 1 deletion packages/bloc_presentation/example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ dev_dependencies:
bloc_test: ^10.0.0
flutter_test:
sdk: flutter
leancode_lint: ">=5.0.0 <7.0.0"
leancode_lint: '>=5.0.0'

flutter:
uses-material-design: true
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,15 @@ class _BlocPresentationListenerBaseState<

void _subscribe() {
_streamSubscription = _bloc.presentation.listen(
(event) => widget.listener(context, event),
(event) {
if (!mounted) {
// This is to satisfy use_build_context_synchronously lint. We
// unsubscribe on dispose so the context should always be mounted here.
return;
}

widget.listener(context, event);
},
);
}

Expand Down
2 changes: 1 addition & 1 deletion packages/bloc_presentation/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: bloc_presentation
description: >
Extends blocs with an additional stream which can serve as a way of indicating
single-time events (so-called "presentation events").
version: 1.0.1
version: 1.1.0
homepage: https://github.com/leancodepl/bloc_presentation/tree/master/packages/bloc_presentation

environment:
Expand Down
Loading