Skip to content

Commit 6ff76ed

Browse files
authored
Merge pull request #239 from Instabug/release/11.0.0
[MOB-8882] Release/11.0.0
2 parents a5193c9 + 4cb1c07 commit 6ff76ed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+443
-1357
lines changed

.circleci/config.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ jobs:
6363
- image: cirrusci/flutter
6464
steps:
6565
- checkout
66-
- run: sudo gem install bundler:1.16.1
66+
- run: sudo gem install bundler:2.1.4
6767
- run: bundle check || sudo bundle install
6868
- run: bundle exec danger
6969
- run: flutter doctor
@@ -79,7 +79,7 @@ jobs:
7979
- image: cirrusci/flutter:2.2.3
8080
steps:
8181
- checkout
82-
- run: sudo gem install bundler:1.16.1
82+
- run: sudo gem install bundler:2.1.4
8383
- run: bundle check || sudo bundle install
8484
- run: bundle exec danger
8585
- run: flutter doctor

CHANGELOG.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,16 @@
1+
## v11.0.0 (2022-07-20)
2+
3+
* Bumps Instabug native SDKs to v11
4+
* Adds the ability to initialize the Android SDK from Dart. Check the migration guide referenced in our docs
5+
* Changes the package importing style for a more conventional use. Check the migration guide referenced in our docs
6+
* Moves InstabugCustomHttpClient used for network logging into a separate repo. Check the migration guide referenced in our docs
7+
* Flutter 3 compatibility
8+
* Bumps Gradle to 6.8 & Android Gradle plugin to 4.1
9+
* Adds BugReporting.setFloatingButtonEdge API
10+
* Removes the string keys bugReportHeader and feedbackReportHeader. Check the migration guide referenced in our docs
11+
* Removes the deprecated APIs. Check the migration guide referenced in our docs
12+
* Fixes an issue with Android screenshots being black on release mode on SDK v10.13.0
13+
114
## v10.13.0 (2022-03-31)
215

316
* Adds support for uploading debug symbols on Android to be used for crash deobfuscation

Gemfile.lock

Lines changed: 56 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,47 +1,77 @@
11
GEM
22
remote: https://rubygems.org/
33
specs:
4-
addressable (2.5.2)
5-
public_suffix (>= 2.0.2, < 4.0)
6-
claide (1.0.2)
4+
addressable (2.8.0)
5+
public_suffix (>= 2.0.2, < 5.0)
6+
claide (1.1.0)
77
claide-plugins (0.9.2)
88
cork
99
nap
1010
open4 (~> 1.3)
1111
colored2 (3.1.2)
1212
cork (0.3.0)
1313
colored2 (~> 3.1)
14-
danger (5.16.1)
14+
danger (8.6.1)
1515
claide (~> 1.0)
1616
claide-plugins (>= 0.9.2)
1717
colored2 (~> 3.1)
1818
cork (~> 0.1)
19-
faraday (~> 0.9)
20-
faraday-http-cache (~> 1.0)
21-
git (~> 1.5)
22-
kramdown (~> 1.5)
19+
faraday (>= 0.9.0, < 2.0)
20+
faraday-http-cache (~> 2.0)
21+
git (~> 1.7)
22+
kramdown (~> 2.3)
23+
kramdown-parser-gfm (~> 1.0)
2324
no_proxy_fix
2425
octokit (~> 4.7)
25-
terminal-table (~> 1)
26-
faraday (0.15.4)
27-
multipart-post (>= 1.2, < 3)
28-
faraday-http-cache (1.3.1)
29-
faraday (~> 0.8)
30-
git (1.5.0)
31-
kramdown (1.17.0)
32-
multipart-post (2.0.0)
26+
terminal-table (>= 1, < 4)
27+
faraday (1.10.0)
28+
faraday-em_http (~> 1.0)
29+
faraday-em_synchrony (~> 1.0)
30+
faraday-excon (~> 1.1)
31+
faraday-httpclient (~> 1.0)
32+
faraday-multipart (~> 1.0)
33+
faraday-net_http (~> 1.0)
34+
faraday-net_http_persistent (~> 1.0)
35+
faraday-patron (~> 1.0)
36+
faraday-rack (~> 1.0)
37+
faraday-retry (~> 1.0)
38+
ruby2_keywords (>= 0.0.4)
39+
faraday-em_http (1.0.0)
40+
faraday-em_synchrony (1.0.0)
41+
faraday-excon (1.1.0)
42+
faraday-http-cache (2.4.0)
43+
faraday (>= 0.8)
44+
faraday-httpclient (1.0.1)
45+
faraday-multipart (1.0.4)
46+
multipart-post (~> 2)
47+
faraday-net_http (1.0.1)
48+
faraday-net_http_persistent (1.2.0)
49+
faraday-patron (1.0.0)
50+
faraday-rack (1.0.0)
51+
faraday-retry (1.0.3)
52+
git (1.11.0)
53+
rchardet (~> 1.8)
54+
kramdown (2.4.0)
55+
rexml
56+
kramdown-parser-gfm (1.1.0)
57+
kramdown (~> 2.0)
58+
multipart-post (2.2.3)
3359
nap (1.1.0)
3460
no_proxy_fix (0.1.2)
35-
octokit (4.13.0)
36-
sawyer (~> 0.8.0, >= 0.5.3)
61+
octokit (4.25.0)
62+
faraday (>= 1, < 3)
63+
sawyer (~> 0.9)
3764
open4 (1.3.4)
38-
public_suffix (3.0.3)
39-
sawyer (0.8.1)
40-
addressable (>= 2.3.5, < 2.6)
41-
faraday (~> 0.8, < 1.0)
42-
terminal-table (1.8.0)
43-
unicode-display_width (~> 1.1, >= 1.1.1)
44-
unicode-display_width (1.5.0)
65+
public_suffix (4.0.7)
66+
rchardet (1.8.0)
67+
rexml (3.2.5)
68+
ruby2_keywords (0.0.5)
69+
sawyer (0.9.2)
70+
addressable (>= 2.3.5)
71+
faraday (>= 0.17.3, < 3)
72+
terminal-table (3.0.2)
73+
unicode-display_width (>= 1.1.1, < 3)
74+
unicode-display_width (2.1.0)
4575

4676
PLATFORMS
4777
ruby
@@ -50,4 +80,4 @@ DEPENDENCIES
5080
danger
5181

5282
BUNDLED WITH
53-
1.16.1
83+
2.1.4

README.md

Lines changed: 22 additions & 82 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,12 @@ A Flutter plugin for [Instabug](https://instabug.com/).
88

99
| Feature | Status |
1010
|:---------------------------------------------------------:|:-------:|
11-
| [Bug Reporting](https://instabug.com/bug-reporting) ||
12-
| [Crash Reporting](https://instabug.com/crash-reporting) ||
13-
| [In-App Chat](https://instabug.com/in-app-chat) ||
14-
| [In-App Surveys](https://instabug.com/in-app-surveys) ||
15-
| [Feature Requests](https://instabug.com/feature-requests) ||
11+
| [Bug Reporting](https://docs.instabug.com/docs/flutter-bug-reporting) ||
12+
| [Crash Reporting](https://docs.instabug.com/docs/flutter-crash-reporting) ||
13+
| [App Performance Monitoring](https://docs.instabug.com/docs/flutter-apm) ||
14+
| [In-App Replies](https://docs.instabug.com/docs/flutter-in-app-replies) ||
15+
| [In-App Surveys](https://docs.instabug.com/docs/flutter-in-app-surveys) ||
16+
| [Feature Requests](https://docs.instabug.com/docs/flutter-in-app-feature-requests) ||
1617

1718
* ✅ Stable
1819
* ⚙️ Under active development
@@ -40,45 +41,16 @@ flutter packages get
4041
To start using Instabug, import it into your Flutter app.
4142

4243
```dart
43-
import 'package:instabug_flutter/Instabug.dart';
44+
import 'package:instabug_flutter/instabug_flutter.dart';
4445
```
45-
* #### iOS
46-
Initialize the SDK in `initState()`. This line enables the SDK with the default behavior and sets it to be shown when the device is shaken.
4746

48-
```dart
49-
Instabug.start('APP_TOKEN', [InvocationEvent.shake]);
50-
```
51-
* #### Android
52-
1. Add the following Maven repository to your project level `build.gradle`
47+
Initialize the SDK in `initState()`. This line enables the SDK with the default behavior and sets it to be shown when the device is shaken.
5348

5449
```dart
55-
allprojects {
56-
repositories {
57-
maven {
58-
url "https://sdks.instabug.com/nexus/repository/instabug-cp"
59-
}
60-
}
61-
}
50+
Instabug.start('APP_TOKEN', [InvocationEvent.shake]);
6251
```
6352

64-
65-
2. Create a new Java class that extends `FlutterApplication` and add it to your `AndroidManifest.xml`.
66-
67-
```xml
68-
<application
69-
android:name=".CustomFlutterApplication"
70-
...
71-
</application>
72-
````
73-
74-
3. In your newly created `CustomFlutterApplication` class, override `onCreate()` and add the following code.
75-
76-
77-
```java
78-
ArrayList<String> invocationEvents = new ArrayList<>();
79-
invocationEvents.add(InstabugFlutterPlugin.INVOCATION_EVENT_SHAKE);
80-
new InstabugFlutterPlugin().start(CustomFlutterApplication.this, "APP_TOKEN", invocationEvents);
81-
```
53+
> :warning: If you're updating the SDK from versions prior to v11, please check our [migration guide](https://docs.instabug.com/docs/flutter-migration-guide).
8254
8355
## Crash reporting
8456

@@ -87,42 +59,21 @@ Instabug automatically captures every crash of your app and sends relevant detai
8759
⚠️ **Crashes will only be reported in release mode and not in debug mode.**
8860

8961

90-
1. Import the following into your `main.dart`:
62+
Replace `void main() => runApp(MyApp());` with the following snippet:
9163

9264
```dart
93-
import 'package:instabug_flutter/CrashReporting.dart';
65+
void main() async {
66+
FlutterError.onError = (FlutterErrorDetails details) {
67+
Zone.current.handleUncaughtError(details.exception, details.stack);
68+
};
69+
runZonedGuarded<Future<void>>(() async {
70+
runApp(MyApp());
71+
}, (Object error, StackTrace stackTrace) {
72+
CrashReporting.reportCrash(error, stackTrace);
73+
});
74+
}
9475
```
9576

96-
2. Replace `void main() => runApp(MyApp());` with the following snippet.
97-
98-
Recommended:
99-
```dart
100-
void main() async {
101-
FlutterError.onError = (FlutterErrorDetails details) {
102-
Zone.current.handleUncaughtError(details.exception, details.stack);
103-
};
104-
runZonedGuarded<Future<void>>(() async {
105-
runApp(MyApp());
106-
}, (Object error, StackTrace stackTrace) {
107-
CrashReporting.reportCrash(error, stackTrace);
108-
});
109-
}
110-
```
111-
112-
For Flutter versions prior to 1.17:
113-
```dart
114-
void main() async {
115-
FlutterError.onError = (FlutterErrorDetails details) {
116-
Zone.current.handleUncaughtError(details.exception, details.stack);
117-
};
118-
runZoned<Future<void>>(() async {
119-
runApp(MyApp());
120-
}, onError: (dynamic error, StackTrace stackTrace) {
121-
CrashReporting.reportCrash(error, stackTrace);
122-
});
123-
}
124-
```
125-
12677
## Repro Steps
12778
Repro Steps list all of the actions an app user took before reporting a bug or crash, grouped by the screens they visited in your app.
12879

@@ -136,18 +87,7 @@ Repro Steps list all of the actions an app user took before reporting a bug or c
13687
⚠️ Screenshots in repro steps on android is not currently supported.
13788

13889
## Network Logging
139-
You can choose to attach all your network requests to the reports being sent to the dashboard. To enable the feature when using the `dart:io` package `HttpClient`, use the custom Instabug client:
140-
```
141-
InstabugCustomHttpClient client = InstabugCustomHttpClient();
142-
```
143-
144-
and continue to use the package normally to make your network requests:
145-
146-
```
147-
client.getUrl(Uri.parse(URL)).then((request) async {
148-
var response = await request.close();
149-
});
150-
```
90+
You can choose to attach all your network requests to the reports being sent to the dashboard. To enable the feature when using the `dart:io` package `HttpClient`, please refer to the [Instabug Dart IO Http Client](https://github.com/Instabug/instabug-dart-io-http-client) repository.
15191

15292
We also support the packages `http` and `dio`. For details on how to enable network logging for these external packages, refer to the [Instabug Dart Http Adapter](https://github.com/Instabug/Instabug-Dart-http-Adapter) and the [Instabug Dio Interceptor](https://github.com/Instabug/Instabug-Dio-Interceptor) repositories.
15393

android/build.gradle

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,18 +4,18 @@ version '1.0-SNAPSHOT'
44
buildscript {
55
repositories {
66
google()
7-
jcenter()
7+
mavenCentral()
88
}
99

1010
dependencies {
11-
classpath 'com.android.tools.build:gradle:3.5.4'
11+
classpath 'com.android.tools.build:gradle:4.1.0'
1212
}
1313
}
1414

1515
rootProject.allprojects {
1616
repositories {
1717
google()
18-
jcenter()
18+
mavenCentral()
1919
}
2020
}
2121

@@ -24,17 +24,24 @@ apply plugin: 'com.android.library'
2424
android {
2525
compileSdkVersion 28
2626

27+
compileOptions {
28+
sourceCompatibility JavaVersion.VERSION_1_8
29+
targetCompatibility JavaVersion.VERSION_1_8
30+
}
31+
2732
defaultConfig {
2833
minSdkVersion 16
2934
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
3035
consumerProguardFiles 'proguard-rules.txt'
3136
}
37+
3238
lintOptions {
3339
disable 'InvalidPackage'
3440
}
3541
}
42+
3643
dependencies {
37-
implementation 'com.instabug.library:instabug:10.13.0'
44+
implementation 'com.instabug.library:instabug:11.3.0'
3845
testImplementation 'junit:junit:4.12'
3946
}
4047

android/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
33
zipStoreBase=GRADLE_USER_HOME
44
zipStorePath=wrapper/dists
5-
distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-all.zip
5+
distributionUrl=https\://services.gradle.org/distributions/gradle-6.8-bin.zip

android/src/main/java/com/instabug/instabugflutter/ArgsRegistry.java

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
import com.instabug.bug.invocation.Option;
55
import com.instabug.featuresrequest.ActionType;
66
import com.instabug.library.InstabugColorTheme;
7+
import com.instabug.library.invocation.util.InstabugFloatingButtonEdge;
78
import com.instabug.library.InstabugCustomTextPlaceHolder;
89
import com.instabug.library.extendedbugreport.ExtendedBugReport;
910
import com.instabug.library.visualusersteps.State;
@@ -56,6 +57,7 @@ final class ArgsRegistry {
5657
registerColorThemeArgs(ARGS);
5758
registerLocaleArgs(ARGS);
5859
registerInvocationOptionsArgs(ARGS);
60+
registerInstabugFloatingButtonEdgeArgs(ARGS);
5961
registerCustomTextPlaceHolderKeysArgs(ARGS);
6062
registerInstabugReportTypesArgs(ARGS);
6163
registerInstabugExtendedBugReportModeArgs(ARGS);
@@ -123,6 +125,11 @@ static void registerColorThemeArgs(Map<String, Object> args) {
123125
args.put("ColorTheme.dark", InstabugColorTheme.InstabugColorThemeDark);
124126
}
125127

128+
static void registerInstabugFloatingButtonEdgeArgs(Map<String, Object> args) {
129+
args.put("FloatingButtonEdge.left", InstabugFloatingButtonEdge.LEFT);
130+
args.put("FloatingButtonEdge.right", InstabugFloatingButtonEdge.RIGHT);
131+
}
132+
126133
static void registerInvocationOptionsArgs(Map<String, Object> args) {
127134
args.put("InvocationOption.commentFieldRequired", Option.COMMENT_FIELD_REQUIRED);
128135
args.put("InvocationOption.disablePostSendingDialog", Option.DISABLE_POST_SENDING_DIALOG);
@@ -162,7 +169,6 @@ static void registerCustomTextPlaceHolderKeysArgs(Map<String, Object> args) {
162169
args.put("CustomTextPlaceHolderKey.invalidEmailMessage", InstabugCustomTextPlaceHolder.Key.INVALID_EMAIL_MESSAGE);
163170
args.put("CustomTextPlaceHolderKey.invalidCommentMessage", InstabugCustomTextPlaceHolder.Key.INVALID_COMMENT_MESSAGE);
164171
args.put("CustomTextPlaceHolderKey.invocationHeader", InstabugCustomTextPlaceHolder.Key.INVOCATION_HEADER);
165-
args.put("CustomTextPlaceHolderKey.startChats", InstabugCustomTextPlaceHolder.Key.START_CHATS);
166172
args.put("CustomTextPlaceHolderKey.reportQuestion", InstabugCustomTextPlaceHolder.Key.REPORT_QUESTION);
167173
args.put("CustomTextPlaceHolderKey.reportBug", InstabugCustomTextPlaceHolder.Key.REPORT_BUG);
168174
args.put("CustomTextPlaceHolderKey.reportFeedback", InstabugCustomTextPlaceHolder.Key.REPORT_FEEDBACK);
@@ -176,8 +182,6 @@ static void registerCustomTextPlaceHolderKeysArgs(Map<String, Object> args) {
176182
args.put("CustomTextPlaceHolderKey.conversationsListTitle", InstabugCustomTextPlaceHolder.Key.CONVERSATIONS_LIST_TITLE);
177183
args.put("CustomTextPlaceHolderKey.audioRecordingPermissionDenied", InstabugCustomTextPlaceHolder.Key.AUDIO_RECORDING_PERMISSION_DENIED);
178184
args.put("CustomTextPlaceHolderKey.conversationTextFieldHint", InstabugCustomTextPlaceHolder.Key.CONVERSATION_TEXT_FIELD_HINT);
179-
args.put("CustomTextPlaceHolderKey.bugReportHeader", InstabugCustomTextPlaceHolder.Key.BUG_REPORT_HEADER);
180-
args.put("CustomTextPlaceHolderKey.feedbackReportHeader", InstabugCustomTextPlaceHolder.Key.FEEDBACK_REPORT_HEADER);
181185
args.put("CustomTextPlaceHolderKey.voiceMessagePressAndHoldToRecord", InstabugCustomTextPlaceHolder.Key.VOICE_MESSAGE_PRESS_AND_HOLD_TO_RECORD);
182186
args.put("CustomTextPlaceHolderKey.voiceMessageReleaseToAttach", InstabugCustomTextPlaceHolder.Key.VOICE_MESSAGE_RELEASE_TO_ATTACH);
183187
args.put("CustomTextPlaceHolderKey.reportSuccessfullySent", InstabugCustomTextPlaceHolder.Key.REPORT_SUCCESSFULLY_SENT);

0 commit comments

Comments
 (0)