Skip to content

Commit b592e14

Browse files
authored
Make the library buildable and the example compilable so we can publish and fix the CI (#139)
* Update obsolete workflow action versions * Updated minimum required ios version of the example to 14 * Update flutter version used by the CI to the latest * unsafe_html was removed in Dart 3.7.0 * Fix The value of 'identity' should be used * Fix workflow upload artifact conflict * Use the latest flutter action in workflow
1 parent 796bf66 commit b592e14

File tree

8 files changed

+19
-23
lines changed

8 files changed

+19
-23
lines changed

.github/workflows/ci.yml

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -11,18 +11,18 @@ jobs:
1111
name: Flutter version ${{ matrix.flutter_version }} (Android)
1212
strategy:
1313
matrix:
14-
flutter_version: ["3.10.2"]
14+
flutter_version: ["3.29.2"]
1515

1616
steps:
17-
- uses: actions/checkout@v2
17+
- uses: actions/checkout@v4
1818
- uses: actions/setup-java@v1
1919
with:
2020
java-version: "11.x"
21-
- uses: subosito/flutter-action@4389e6cbc6cb8a4b18c628ff96ff90be0e926aa8
21+
- uses: subosito/flutter-action@v2
2222
with:
2323
flutter-version: ${{ matrix.flutter_version }}
2424
- name: Cache Dart and Gradle packages
25-
uses: actions/cache@v2
25+
uses: actions/cache@v4
2626
with:
2727
path: |
2828
~/.gradle/caches
@@ -69,13 +69,13 @@ jobs:
6969
- name: Build rollbar_flutter Android example
7070
working-directory: ./rollbar_flutter/example/
7171
run: flutter build apk
72-
- uses: actions/upload-artifact@v2
72+
- uses: actions/upload-artifact@v4
7373
if: ${{ always() }}
7474
# We are not supposed to lock our dependencies in packages or plugins, so we'll
7575
# at least keep track of which ones were used in the build, in case a test fails
7676
# and we need to reproduce it locally with the same dependencies.
7777
with:
78-
name: dependencies_used_${{ matrix.flutter_version }}
78+
name: dependencies_used_${{ runner.os }}_${{ matrix.flutter_version }}_${{ github.run_id }}
7979
path: |
8080
rollbar_dart/pubspec.lock
8181
rollbar_dart/example/pubspec.lock
@@ -87,15 +87,15 @@ jobs:
8787
name: Flutter version ${{ matrix.flutter_version }} (iOS)
8888
strategy:
8989
matrix:
90-
flutter_version: ["3.10.2"]
90+
flutter_version: ["3.29.2"]
9191

9292
steps:
93-
- uses: actions/checkout@v2
94-
- uses: subosito/flutter-action@4389e6cbc6cb8a4b18c628ff96ff90be0e926aa8
93+
- uses: actions/checkout@v4
94+
- uses: subosito/flutter-action@v2
9595
with:
9696
flutter-version: ${{ matrix.flutter_version }}
9797
- name: Cache pub packages
98-
uses: actions/cache@v2
98+
uses: actions/cache@v4
9999
with:
100100
path: |
101101
${{ env.PUB_CACHE }}
@@ -109,11 +109,11 @@ jobs:
109109
- name: Build rollbar_flutter iOS example
110110
working-directory: ./rollbar_flutter/example/
111111
run: flutter build ios --no-codesign
112-
- uses: actions/upload-artifact@v2
112+
- uses: actions/upload-artifact@v4
113113
if: ${{ always() }}
114114
# Save dependencies used
115115
with:
116-
name: dependencies_used_${{ matrix.flutter_version }}
116+
name: dependencies_used_${{ runner.os }}_${{ matrix.flutter_version }}_${{ github.run_id }}
117117
path: |
118118
rollbar_dart/pubspec.lock
119119
rollbar_dart/example/pubspec.lock

rollbar_dart/analysis_options.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,6 @@ linter:
1717
- prefer_single_quotes
1818
- sort_child_properties_last
1919
- unawaited_futures
20-
- unsafe_html
21-
2220
# For more information about the core and recommended set of lints, see
2321
# https://dart.dev/go/core-lints
2422

rollbar_flutter/analysis_options.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,5 @@ linter:
1818
- always_declare_return_types
1919
- prefer_single_quotes
2020
- unawaited_futures
21-
- unsafe_html
22-
2321
# Additional information about this file can be found at
2422
# https://dart.dev/guides/language/analysis-options

rollbar_flutter/example/ios/Flutter/AppFrameworkInfo.plist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,6 @@
2121
<key>CFBundleVersion</key>
2222
<string>1.0</string>
2323
<key>MinimumOSVersion</key>
24-
<string>11.0</string>
24+
<string>14.0</string>
2525
</dict>
2626
</plist>

rollbar_flutter/example/ios/Podfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
platform :ios, '11.0'
1+
platform :ios, '14.0'
22

33
# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
44
ENV['COCOAPODS_DISABLE_STATS'] = 'true'

rollbar_flutter/example/ios/Runner.xcodeproj/project.pbxproj

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -353,7 +353,7 @@
353353
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
354354
GCC_WARN_UNUSED_FUNCTION = YES;
355355
GCC_WARN_UNUSED_VARIABLE = YES;
356-
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
356+
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
357357
MTL_ENABLE_DEBUG_INFO = NO;
358358
SDKROOT = iphoneos;
359359
SUPPORTED_PLATFORMS = iphoneos;
@@ -429,7 +429,7 @@
429429
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
430430
GCC_WARN_UNUSED_FUNCTION = YES;
431431
GCC_WARN_UNUSED_VARIABLE = YES;
432-
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
432+
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
433433
MTL_ENABLE_DEBUG_INFO = YES;
434434
ONLY_ACTIVE_ARCH = YES;
435435
SDKROOT = iphoneos;
@@ -478,7 +478,7 @@
478478
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
479479
GCC_WARN_UNUSED_FUNCTION = YES;
480480
GCC_WARN_UNUSED_VARIABLE = YES;
481-
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
481+
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
482482
MTL_ENABLE_DEBUG_INFO = NO;
483483
SDKROOT = iphoneos;
484484
SUPPORTED_PLATFORMS = iphoneos;

rollbar_flutter/ios/rollbar_flutter.podspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ Connect your Flutter applications to Rollbar for error reporting.
1818
s.dependency 'Flutter'
1919
s.dependency 'RollbarNotifier', '~> 3.3.3'
2020
s.static_framework = true
21-
s.platform = :ios, '11.0'
21+
s.platform = :ios, '14.0'
2222

2323
# Flutter.framework does not contain a i386 slice.
2424
s.pod_target_xcconfig = { 'DEFINES_MODULE' => 'YES',

rollbar_flutter/lib/src/platform_transformer.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ extension _Message on Iterable<Trace> {
6161
(extraTraces.tryFirst?.exception.message)
6262
.map((message) => 'PlatformException(error, "$message")')
6363
.map(replaceExceptionMessages)
64-
.map(append ? extraTraces.followedBy : identity)
64+
.map(append ? extraTraces.followedBy : (x) => x)
6565
.or(this);
6666

6767
/// Propagates the given [message] as the new exception message, replacing

0 commit comments

Comments
 (0)