Issue 1:
Steps to Reproduce

create new plugin

flutter create --org com.example --template=plugin utf8err

modify file utf8err\android\src\main\java\com\example\utf8err\Utf8errPlugin.java content to:

package com.example.utf8err;

import io.flutter.plugin.common.MethodChannel;
import io.flutter.plugin.common.MethodChannel.MethodCallHandler;
import io.flutter.plugin.common.MethodChannel.Result;
import io.flutter.plugin.common.MethodCall;
import io.flutter.plugin.common.PluginRegistry.Registrar;

/**
* Utf8errPlugin
*/
public class Utf8errPlugin implements MethodCallHandler {
/**
* Plugin registration.
*/
public static void registerWith(Registrar registrar) {
final MethodChannel channel = new MethodChannel(registrar.messenger(), "utf8err");
JavaError;//<--------------Any wrong statement
channel.setMethodCallHandler(new Utf8errPlugin());
}

@Override
public void onMethodCall(MethodCall call, Result result) {
if (call.method.equals("getPlatformVersion")) {
result.success("Android " + android.os.Build.VERSION.RELEASE);
} else {
result.notImplemented();
}
}
}

run the example:

flutter run

Logs

Run your application with flutter run and attach all the log output.

Launching lib/main.dart on EVA CL00 in debug mode...
Initializing gradle... 1.8s
Resolving dependencies... 4.0s
Running 'gradlew assembleDebug'... \
Oops; flutter has exited unexpectedly.
Sending crash report to Google.
Failed to send crash report due to a network error: SocketException: OS Error: 信号灯超时时间已到
, errno = 121, address = clients2.google.com, port = 26221
Crash report written to D:\skydrive\flutter\utf8err\example\flutter_01.log;
please let us know at https://github.com/flutter/flutter/issues.

the flutter_01.log:

Flutter crash report; please file at https://github.com/flutter/flutter/issues.

## command

flutter run

## exception

FormatException: FormatException: Bad UTF-8 encoding 0xb4 (at offset 93)
``
#0 _Utf8Decoder.convert (dart:convert/utf.dart:574)
#1 _Utf8ConversionSink.addSlice (dart:convert/string_conversion.dart:345)
#2 _Utf8ConversionSink.add (dart:convert/string_conversion.dart:341)
#3 _ConverterStreamEventSink.add (dart:convert/chunked_conversion.dart:86)
#4 _SinkTransformerStreamSubscription._handleData (dart:async/stream_transformers.dart:120)
#5 _rootRunUnary (dart:async/zone.dart:1134)
#6 _CustomZone.runUnary (dart:async/zone.dart:1031)
#7 _CustomZone.runUnaryGuarded (dart:async/zone.dart:933)
#8 _BufferingStreamSubscription._sendData (dart:async/stream_impl.dart:330)
#9 _BufferingStreamSubscription._add (dart:async/stream_impl.dart:257)
#10 _StreamController&&_SyncStreamControllerDispatch._sendData (dart:async/stream_controller.dart:763)
#11 _StreamController._add (dart:async/stream_controller.dart:639)
#12 _StreamController.add (dart:async/stream_controller.dart:585)
#13 _Socket._onData (dart:io-patch/socket_patch.dart:1654)
#14 _rootRunUnary (dart:async/zone.dart:1138)
#15 _CustomZone.runUnary (dart:async/zone.dart:1031)
#16 _CustomZone.runUnaryGuarded (dart:async/zone.dart:933)
#17 _BufferingStreamSubscription._sendData (dart:async/stream_impl.dart:330)
#18 _BufferingStreamSubscription._add (dart:async/stream_impl.dart:257)
#19 _StreamController&&_SyncStreamControllerDispatch._sendData (dart:async/stream_controller.dart:763)
#20 _StreamController._add (dart:async/stream_controller.dart:639)
#21 _StreamController.add (dart:async/stream_controller.dart:585)
#22 new _RawSocket.<anonymous closure> (dart:io-patch/socket_patch.dart:1231)
#23 _NativeSocket.issueReadEvent.issue (dart:io-patch/socket_patch.dart:784)
#24 _microtaskLoop (dart:async/schedule_microtask.dart:41)
#25 _startMicrotaskLoop (dart:async/schedule_microtask.dart:50)
#26 _runPendingImmediateCallback (dart:isolate-patch/dart:isolate/isolate_patch.dart:113)
#27 _RawReceivePortImpl._handleMessage (dart:isolate-patch/dart:isolate/isolate_patch.dart:166)
``

Run flutter analyze and attach any output of that command also.

Analyzing D:\skydrive\flutter\utf8err\example...
No issues found!
Ran in 8.0s

Flutter Doctor

Paste the output of running flutter doctor -v here.

[√] Flutter (Channel beta, v0.1.5, on Microsoft Windows [Version 10.0.16299.309], locale zh-CN)
• Flutter version 0.1.5 at C:\flutter
• Framework revision 3ea4d06340 (4 weeks ago), 2018-02-22 11:12:39 -0800
• Engine revision ead227f118
• Dart version 2.0.0-dev.28.0.flutter-0b4f01f759

[√] Android toolchain - develop for Android devices (Android SDK 27.0.3)
• Android SDK at C:\AndroidSDK
• Android NDK location not configured (optional; useful for native profiling support)
• Platform android-27, build-tools 27.0.3
• ANDROID_HOME = C:\AndroidSDK
• Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
• Java version OpenJDK Runtime Environment (build 1.8.0_152-release-915-b01)

[√] Android Studio (version 3.0)
• Android Studio at C:\Program Files\Android\Android Studio
• Java version OpenJDK Runtime Environment (build 1.8.0_152-release-915-b01)

[!] IntelliJ IDEA Ultimate Edition (version 2017.2)
X Flutter plugin not installed; this adds Flutter specific functionality.
X Dart plugin not installed; this adds Dart specific functionality.
• For information about installing plugins, see
https://flutter.io/intellij-setup/#installing-the-plugins

[√] VS Code (version 1.21.1)
• VS Code at C:\Program Files\Microsoft VS Code
• Dart Code extension version 2.10.0

[√] Connected devices (1 available)
• EVA CL00 • GXK0216410000254 • android-arm64 • Android 7.0 (API 24)

! Doctor found issues in 1 category.

For more information about diagnosing and reporting Flutter bugs, please see https://flutter.io/bug-reports/.

Issue 2:
Steps to Reproduce

Create a Material scaffold flutter app that does not use push.

Make sure aps-environment is not set.

And that the App ID settings on the Developer portal do not have Push enabled.

Build for iOS

Submit a build to Apple TestFlight.

You'll get an email warning you that you haven't set your aps-environment entitlement.

It's not going to get the app rejected, but it's annoying.

Is there a dependency in Flutter that is causing this? We can't find a trace of APNS usage in our app. Thanks!

Tobin