Pass uri instead of filepaths when hot-reloading. (#21201)
* Pass uri instead of filepaths when hot-reloading.
Bug: https://github.com/flutter/flutter/issues/21168
* Remove imports. Enable another test
* Restore skipping of test on mac
diff --git a/packages/flutter_tools/lib/src/vmservice.dart b/packages/flutter_tools/lib/src/vmservice.dart
index fb01e34..51bc7fa 100644
--- a/packages/flutter_tools/lib/src/vmservice.dart
+++ b/packages/flutter_tools/lib/src/vmservice.dart
@@ -1149,13 +1149,11 @@
final Map<String, dynamic> arguments = <String, dynamic>{
'pause': pause
};
- // TODO(goderbauer): Transfer Uri (instead of file path) when remote end supports it.
- // Note: Despite the name, `rootLibUri` and `packagesUri` expect file paths.
if (rootLibUri != null) {
- arguments['rootLibUri'] = rootLibUri.toFilePath(windows: false);
+ arguments['rootLibUri'] = rootLibUri.toString();
}
if (packagesUri != null) {
- arguments['packagesUri'] = packagesUri.toFilePath(windows: false);
+ arguments['packagesUri'] = packagesUri.toString();
}
final Map<String, dynamic> response = await invokeRpcRaw('_reloadSources', params: arguments);
return response;