Unverified Commit b9274c7c authored by Jonah Williams's avatar Jonah Williams Committed by GitHub

[flutter_tools] bypass pubspec yaml content check when running pubdependencies (#66559)

Otherwise the heuristics we have may decide to skip running pub. We should consider reducing the number of dimensions of caching here to a single check optimized for the run/test case.
parent ee6d4c65
...@@ -647,7 +647,7 @@ class PubDependencies extends ArtifactSet { ...@@ -647,7 +647,7 @@ class PubDependencies extends ArtifactSet {
logger: _logger, logger: _logger,
throwOnError: false, throwOnError: false,
); );
if (packageConfig == null || packageConfig == PackageConfig.empty ) { if (packageConfig == null || packageConfig == PackageConfig.empty) {
return false; return false;
} }
for (final Package package in packageConfig.packages) { for (final Package package in packageConfig.packages) {
...@@ -667,6 +667,8 @@ class PubDependencies extends ArtifactSet { ...@@ -667,6 +667,8 @@ class PubDependencies extends ArtifactSet {
context: PubContext.pubGet, context: PubContext.pubGet,
directory: _fileSystem.path.join(_flutterRoot(), 'packages', 'flutter_tools'), directory: _fileSystem.path.join(_flutterRoot(), 'packages', 'flutter_tools'),
generateSyntheticPackage: false, generateSyntheticPackage: false,
skipPubspecYamlCheck: true,
checkLastModified: false,
); );
} }
} }
......
...@@ -744,6 +744,8 @@ void main() { ...@@ -744,6 +744,8 @@ void main() {
context: PubContext.pubGet, context: PubContext.pubGet,
directory: 'packages/flutter_tools', directory: 'packages/flutter_tools',
generateSyntheticPackage: false, generateSyntheticPackage: false,
skipPubspecYamlCheck: true,
checkLastModified: false,
)).called(1); )).called(1);
}); });
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment