Issue 1:
Steps to Reproduce

I'm using Powershell from within VSCode, and about 30% of the time flutter run will crash at the Installing build\app/outputs/apk/app.apk... step.

If I immediately try adb install -r build\app\outputs\apk\app.apk the install succeeds with no issue, but obviously no debugging.

I've tried doing adb kill-server before each run. I've tried flutter run --no-build. Nothing works 100% of the time, and the logs all look identical.

I'm going to start regularly using -v so I can maybe give better logs next time it happens.

(Don't mind the host error, I was offline this last time.)

Shell log

Launching lib/main.dart on LG H910 in debug mode...
Running 'gradle assembleDebug'...
Built build\app/outputs/apk/app-debug.apk (21.9MB).
Installing build\app/outputs/apk/app.apk...

Oops; flutter has exited unexpectedly: "Exit code 1 from: C:\Android\sdk\platform-tools\adb -s LGH9107a67a5fd install -r build\app
/outputs/apk/app.apk".
Sending crash report to Google.
Failed to send crash report due to a network error: SocketException: Failed host lookup: 'clients2.google.com' (OS Error: No such
host is known.
, errno = 11001)
Crash report written to C:\Users\Kyle\Source\Flutter\Cybertronix\flutter_11.log;
please let us know at https://github.com/flutter/flutter/issues.

flutter_11.log

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

command

flutter run

exception

String: Exit code 1 from: C:\Android\sdk\platform-tools\adb -s LGH9107a67a5fd install -r build\app/outputs/apk/app.apk

#0 runCheckedAsync (package:flutter_tools/src/base/process.dart:214)
<asynchronous suspension>
#1 AndroidDevice.installApp (package:flutter_tools/src/android/android_device.dart:241)
<asynchronous suspension>
#2 AndroidDevice._installLatestApp (package:flutter_tools/src/android/android_device.dart:281)
<asynchronous suspension>
#3 AndroidDevice.startApp (package:flutter_tools/src/android/android_device.dart:335)
<asynchronous suspension>
#4 HotRunner.run (package:flutter_tools/src/run_hot.dart:203)
<asynchronous suspension>
#5 RunCommand.runCommand (package:flutter_tools/src/commands/run.dart:291)
<asynchronous suspension>
#6 FlutterCommand.verifyThenRunCommand (package:flutter_tools/src/runner/flutter_command.dart:151)
<asynchronous suspension>
#7 RunCommand.verifyThenRunCommand (package:flutter_tools/src/commands/run.dart:205)
<asynchronous suspension>
#8 FlutterCommand.run (package:flutter_tools/src/runner/flutter_command.dart:121)
#9 CommandRunner.runCommand (package:args/command_runner.dart:194)
<asynchronous suspension>
#10 FlutterCommandRunner.runCommand (package:flutter_tools/src/runner/flutter_command_runner.dart:262)
<asynchronous suspension>
#11 CommandRunner.run.<anonymous closure> (package:args/command_runner.dart:109)
#12 Future.Future.sync (dart:async/future.dart:208)
#13 CommandRunner.run (package:args/command_runner.dart:109)
#14 FlutterCommandRunner.run (package:flutter_tools/src/runner/flutter_command_runner.dart:157)
#15 run.<anonymous closure> (package:flutter_tools/executable.dart:140)
<asynchronous suspension>
#16 AppContext._run (package:flutter_tools/src/base/context.dart:76)
<asynchronous suspension>
#17 AppContext.runInZone.<anonymous closure> (package:flutter_tools/src/base/context.dart:66)
#18 _rootRun (dart:async/zone.dart:1120)
#19 _CustomZone.run (dart:async/zone.dart:1001)
#20 runZoned (dart:async/zone.dart:1465)
#21 AppContext.runInZone (package:flutter_tools/src/base/context.dart:65)
#22 run (package:flutter_tools/executable.dart:113)
<asynchronous suspension>
#23 main (package:flutter_tools/executable.dart:66)
<asynchronous suspension>
#24 main (file:///C:/flutter/packages/flutter_tools/bin/flutter_tools.dart:8)
#25 _startIsolate.<anonymous closure> (dart:isolate-patch/isolate_patch.dart:263)
#26 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:151)

flutter doctor

[✓] Flutter (on Microsoft Windows [Version 6.3.9600], channel master)
• Flutter at C:\flutter
• Framework revision e2cd78358f (19 hours ago), 2017-04-26 13:14:31 -0700
• Engine revision a5b64899c9
• Tools Dart version 1.23.0-dev.11.11

[✓] Host Executable Compatibility
• Downloaded executables execute on host

[✓] Android toolchain - develop for Android devices (Android SDK 25.0.2)
• Android SDK at C:\Android\sdk
• Platform android-25, build-tools 25.0.2
• ANDROID_HOME = C:\Android\sdk
• Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
• Java version: OpenJDK Runtime Environment (build 1.8.0_112-release-b06)

[✓] Android Studio (version 2.3)
• Android Studio at C:\Program Files\Android\Android Studio
• Gradle version 3.2
• Java version: OpenJDK Runtime Environment (build 1.8.0_112-release-b06)

[✓] IntelliJ IDEA Community Edition (version 2016.3)
• Dart plugin version 163.13137
• Flutter plugin version 0.1.11.2

[✓] Connected devices
• LG H910 • LGH9107a67a5fd • android-arm • Android 7.0 (API 24)

Issue 2:
Steps to Reproduce

Attempt to run from Android Studio on Windows 10. Sometimes the following dialog appears:

Workaround: Cancelling the dialog and trying again eventually resolves the problem.

@goderbauer requested that I file this issue.

Logs

$ adb install-multiple -r ...\android\app\build\intermediates\split-apk\debug\slices\slice_4.apk ...\android\app\build\intermediates\split-apk\debug\slices\slice_3.apk ...\android\app\build\intermediates\split-apk\debug\slices\slice_9.apk ...\android\app\build\intermediates\split-apk\debug\slices\slice_5.apk ...\android\app\build\intermediates\split-apk\debug\slices\slice_8.apk ...\android\app\build\intermediates\split-apk\debug\slices\slice_7.apk ...\android\app\build\intermediates\split-apk\debug\slices\slice_6.apk ...\android\app\build\intermediates\split-apk\debug\dep\dependencies.apk ...\android\app\build\intermediates\split-apk\debug\slices\slice_1.apk ...\android\app\build\intermediates\split-apk\debug\slices\slice_2.apk ...\android\app\build\intermediates\split-apk\debug\slices\slice_0.apk ...\android\app\build\outputs\apk\app-debug.apk
Error while Installing APKs

Flutter Doctor

[√] Flutter (on Windows, channel master)
• Flutter at C:\dev\flutter
• Framework revision ca0201d8ae (3 days ago),
• Engine revision 342a31136e
• Tools Dart version 1.23.0-dev.2.0

[√] Android toolchain - develop for Android devices (Android SDK 25.0.2)
• Android SDK at C:\Users\Rob\AppData\Local\Android\sdk
• Platform android-25, build-tools 25.0.2
• Java(TM) SE Runtime Environment (build 1.8.0_121-b13)

[√] Android Studio (version 2.3)
• Android Studio at C:\Program Files\Android\Android Studio
• Gradle version 3.2

[√] IntelliJ IDEA Community Edition (version 2016.3)
• Dart plugin version 163.13137
• Flutter plugin version 0.1.11.1

[√] Connected devices
• 2PS64 • HT69N0100346 • android-arm • Android 7.0 (API 24)