Unverified Commit 4bd5eb59 authored by Jonah Williams's avatar Jonah Williams Committed by GitHub

Enable track widget creation on by default (#43471)

parent 02abd00e
...@@ -514,7 +514,7 @@ class DefaultResidentCompiler implements ResidentCompiler { ...@@ -514,7 +514,7 @@ class DefaultResidentCompiler implements ResidentCompiler {
String sdkRoot, { String sdkRoot, {
@required this.buildMode, @required this.buildMode,
this.causalAsyncStacks = true, this.causalAsyncStacks = true,
this.trackWidgetCreation = false, this.trackWidgetCreation = true,
this.packagesPath, this.packagesPath,
this.fileSystemRoots, this.fileSystemRoots,
this.fileSystemScheme, this.fileSystemScheme,
......
...@@ -361,7 +361,7 @@ abstract class FlutterCommand extends Command<void> { ...@@ -361,7 +361,7 @@ abstract class FlutterCommand extends Command<void> {
argParser.addFlag( argParser.addFlag(
'track-widget-creation', 'track-widget-creation',
hide: !hasEffect && !verboseHelp, hide: !hasEffect && !verboseHelp,
defaultsTo: false, // this will soon be changed to true defaultsTo: true,
help: 'Track widget creation locations. This enables features such as the widget inspector. ' help: 'Track widget creation locations. This enables features such as the widget inspector. '
'This parameter is only functional in debug mode (i.e. when compiling JIT, not AOT).', 'This parameter is only functional in debug mode (i.e. when compiling JIT, not AOT).',
); );
......
...@@ -62,7 +62,8 @@ void main() { ...@@ -62,7 +62,8 @@ void main() {
testUsingContext('report which user created widget caused the error - no flag', () async { testUsingContext('report which user created widget caused the error - no flag', () async {
Cache.flutterRoot = '../..'; Cache.flutterRoot = '../..';
return _testFile('print_user_created_ancestor_no_flag', automatedTestsDirectory, flutterTestDirectory); return _testFile('print_user_created_ancestor_no_flag', automatedTestsDirectory, flutterTestDirectory,
extraArguments: const <String>['--no-track-widget-creation']);
}, skip: io.Platform.isWindows); // TODO(chunhtai): Dart on Windows has trouble with unicode characters in output (#35425). }, skip: io.Platform.isWindows); // TODO(chunhtai): Dart on Windows has trouble with unicode characters in output (#35425).
testUsingContext('report correct created widget caused the error', () async { testUsingContext('report correct created widget caused the error', () async {
......
...@@ -209,7 +209,7 @@ flutter: ...@@ -209,7 +209,7 @@ flutter:
gradlew, gradlew,
'-q', '-q',
'-Ptarget=${fs.path.join(tempDir.path, 'flutter_project', 'lib', 'main.dart')}', '-Ptarget=${fs.path.join(tempDir.path, 'flutter_project', 'lib', 'main.dart')}',
'-Ptrack-widget-creation=false', '-Ptrack-widget-creation=true',
'-Pshrink=true', '-Pshrink=true',
'-Ptarget-platform=android-arm,android-arm64,android-x64', '-Ptarget-platform=android-arm,android-arm64,android-x64',
'assembleRelease', 'assembleRelease',
...@@ -241,7 +241,7 @@ flutter: ...@@ -241,7 +241,7 @@ flutter:
gradlew, gradlew,
'-q', '-q',
'-Ptarget=${fs.path.join(tempDir.path, 'flutter_project', 'lib', 'main.dart')}', '-Ptarget=${fs.path.join(tempDir.path, 'flutter_project', 'lib', 'main.dart')}',
'-Ptrack-widget-creation=false', '-Ptrack-widget-creation=true',
'-Ptarget-platform=android-arm,android-arm64,android-x64', '-Ptarget-platform=android-arm,android-arm64,android-x64',
'assembleRelease', 'assembleRelease',
], ],
...@@ -265,7 +265,7 @@ flutter: ...@@ -265,7 +265,7 @@ flutter:
gradlew, gradlew,
'-q', '-q',
'-Ptarget=${fs.path.join(tempDir.path, 'flutter_project', 'lib', 'main.dart')}', '-Ptarget=${fs.path.join(tempDir.path, 'flutter_project', 'lib', 'main.dart')}',
'-Ptrack-widget-creation=false', '-Ptrack-widget-creation=true',
'-Pshrink=true', '-Pshrink=true',
'-Ptarget-platform=android-arm,android-arm64,android-x64', '-Ptarget-platform=android-arm,android-arm64,android-x64',
'assembleRelease', 'assembleRelease',
...@@ -321,7 +321,7 @@ flutter: ...@@ -321,7 +321,7 @@ flutter:
gradlew, gradlew,
'-q', '-q',
'-Ptarget=${fs.path.join(tempDir.path, 'flutter_project', 'lib', 'main.dart')}', '-Ptarget=${fs.path.join(tempDir.path, 'flutter_project', 'lib', 'main.dart')}',
'-Ptrack-widget-creation=false', '-Ptrack-widget-creation=true',
'-Pshrink=true', '-Pshrink=true',
'-Ptarget-platform=android-arm,android-arm64,android-x64', '-Ptarget-platform=android-arm,android-arm64,android-x64',
'assembleRelease', 'assembleRelease',
...@@ -374,7 +374,7 @@ flutter: ...@@ -374,7 +374,7 @@ flutter:
gradlew, gradlew,
'-q', '-q',
'-Ptarget=${fs.path.join(tempDir.path, 'flutter_project', 'lib', 'main.dart')}', '-Ptarget=${fs.path.join(tempDir.path, 'flutter_project', 'lib', 'main.dart')}',
'-Ptrack-widget-creation=false', '-Ptrack-widget-creation=true',
'-Pshrink=true', '-Pshrink=true',
'-Ptarget-platform=android-arm,android-arm64,android-x64', '-Ptarget-platform=android-arm,android-arm64,android-x64',
'assembleRelease', 'assembleRelease',
......
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