fix some call sites of printError (#11724)
* fix some call sites of printError * review comments
This commit is contained in:
@@ -468,7 +468,7 @@ abstract class ResidentRunner {
|
||||
await view.uiIsolate.flutterDebugAllowBanner(false);
|
||||
} catch (error) {
|
||||
status.stop();
|
||||
printError(error);
|
||||
printError('Error communicating with Flutter on the device: $error');
|
||||
}
|
||||
}
|
||||
try {
|
||||
@@ -480,7 +480,7 @@ abstract class ResidentRunner {
|
||||
await view.uiIsolate.flutterDebugAllowBanner(true);
|
||||
} catch (error) {
|
||||
status.stop();
|
||||
printError(error);
|
||||
printError('Error communicating with Flutter on the device: $error');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -88,7 +88,7 @@ class ColdRunner extends ResidentRunner {
|
||||
try {
|
||||
await downloadStartupTrace(device.vmServices.first);
|
||||
} catch (error) {
|
||||
printError(error);
|
||||
printError('Error downloading startup trace: $error');
|
||||
return 2;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -31,8 +31,8 @@ Future<Null> parseServiceConfigs(
|
||||
Map<String, Uri> packageMap;
|
||||
try {
|
||||
packageMap = new PackageMap(PackageMap.globalPackagesPath).map;
|
||||
} on FormatException catch(e) {
|
||||
printTrace('Invalid ".packages" file while parsing service configs:\n$e');
|
||||
} on FormatException catch (error) {
|
||||
printTrace('Invalid ".packages" file while parsing service configs:\n$error');
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -40,9 +40,9 @@ Future<Null> parseServiceConfigs(
|
||||
try {
|
||||
manifest = _loadYamlFile(_kFlutterManifestPath);
|
||||
manifest = manifest['flutter'];
|
||||
} catch (e) {
|
||||
} catch (error) {
|
||||
printStatus('Error detected in pubspec.yaml:', emphasis: true);
|
||||
printError(e);
|
||||
printError('$error');
|
||||
return;
|
||||
}
|
||||
if (manifest == null || manifest['services'] == null) {
|
||||
|
||||
Reference in New Issue
Block a user