Skip first time full dill transfer (#21133)

* Don't sync first full kernel file.

* Update the comment
This commit is contained in:
Alexander Aprelev 2018-09-13 09:01:47 -07:00 committed by GitHub
parent d107ff9d48
commit 199422cd2d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -509,6 +509,9 @@ class DevFS {
outputPath: dillOutputPath ?? fs.path.join(getBuildDirectory(), 'app.dill'),
packagesFilePath : _packagesFilePath,
);
// Don't send full kernel file that would overwrite what VM already
// started loading from.
if (!bundleFirstUpload) {
final String compiledBinary = compilerOutput?.outputFilename;
if (compiledBinary != null && compiledBinary.isNotEmpty) {
final Uri entryUri = fs.path.toUri(projectRootPath != null
@ -521,6 +524,7 @@ class DevFS {
numBytes += content.size;
}
}
}
if (dirtyEntries.isNotEmpty) {
printTrace('Updating files');
if (_httpWriter != null) {