update flutter precache --force to delete all stamp files. In the event that a user is hitting a cache issue, this should be easier than re-downloading all artifacts or manually blowing away the cache.
This is probably how it should have worked in the first place
This field is used to look-up the event in the platform
that resuted a given `PointerEvent`. This is currently only
used on Android, where the `embedderId` is set to be the
`motionEventId` for a given `MotionEvent`.
Roll engine to d0d6a4c2362d2ed478006bb3b01c34c0e96033b4
Remove globals from flutter_tester device and cleanup test case. Not completely gone since the Kernel Builder will still use them, but a good incremental improvement.
* First pass at CMake files; untested
* First pass of adding CMake generation logic on Windows
* Misc fixes
* Get bundling working, start incoprorating CMake build into tool
* Fix debug, exe name.
* Add resources
* Move cmake.dart
* Rip out all the vcxproj/solution plumbing
* Fix plugin cmake generation
* Build with cmake rather than calling VS directly
* Adjust Windows plugin template to match standard header directory structure
* Pass config selection when building
* Partially fix multi-config handling
* Rev template version
* Share the CMake generation instead of splitting it out
* VS build/run cycle works, with slightly awkward requirement to always build all
* Update manifest
* Plugin template fixes
* Minor adjustments
* Build install as part of build command, instead of separately
* Test cleanup
* Update Linux test for adjusted generated CMake approach
* Plugin test typo fix
* Add missing stub file for project test
* Add a constant for VS generator
initialize from dill does not handle changing null-safety flags and will incorrectly use the nullability mode of the last compile. Add all extra frontend options to the unique name prefix for the flutter run dill cache to avoid this situation.
In web debug mode, infer sound null safety by default. When sound null safety is enabled, provide a separate dill and precompiled Dart SDK. Release builds do not need this setting since we run dart2js from source.
Fixes#59873
The flutter daemon unconditionally waits for the appFinished signal, even if startup failed. Ensure this future is correctly completed if there is a failure in ResidentRunner.run and not just ResidentRunner.attach. Adds regression tests for run release, debug, debug web, and release web. Adds missing try catch in cold runner startup.
Manually tested with release/debug on Android and release/debug on web.
Fixes#60613
Remove unnecessary use of globals from base tests, and an android test. This changes the test to avoid bouncing through the global getters, which can lead to incorrectly cached zone values. Switches the memory filesystem implementation to the test implementation
The global packages path could cause tests to fail when it would be overriden to unexpected (in test setup) values. Remove most usage and make it a configuration on buildInfo, along with most other build information. Cleanup the asset builder to require the .packages path and the resident runners to no longer require it, since they already have the information in build_info.
It needs to stick around for the fuchsia deps we do not control.
Filled #60232 for remaining work.
First pass at fixing #57985 and implementing #59602
This doesn't have enough metadata to be useful for IDEs yet, but it prevents the issue from getting worse while we iterate on it.
WebAssetServer could fail if some of the global statics it depended on were initialized in a different order. Fix this by removing globals.
Delete dwds startup test that needs to spawn a real server.
Remove the version checking and associated warnings. The Linux template
and build process will now be subject to more typical Flutter breaking
change policy, and should no longer require regularly deleting and
recreating the platform directory.
The vm_service_integration test flake is caused by trying to call the method before the framework is initialized (and the extension added). The run errors failure is caused by the error taking some time to propagate to the harness
Update all versions, specifically file which fixes some bugs that caused tests to fail if run in different orders:
- systemTemp directories created by MemoryFileSystem will allot names based on the file system instance instead of globally.
- MemoryFile.readAsLines()/readAsLinesSync() no longer treat a final newline in the file as the start of a new, empty line.
- RecordingFile.readAsLine()/readAsLinesSync() now always record a final newline.
This is a PR addressing #57226 - Proposal: New UI for Licenses Page.
This PR replaces the previous single panel license page with one that uses a master/detail flow (MDFlow) to display packages and their respective licenses.
The License Page API remains unchanged. The logic for processing the license data is kept largely the same. This PR changes how the licenses are displayed, by introducing a responsive UI using the master/detail UI pattern. For now I am calling it Master Detail Flow, or MDFlow.
MDFlow manifests as two layouts depending on the screen size. On small and medium displays, as determined by the breakpoints given by the Material Design Spec, MDFlow utilises a nested layout. On large displays, MDFlow uses a two panel (lateral) layout. MDFlow is implemented in this PR using a Navigator for the nested layout, and a Stack for the lateral layout. The master and detail views are built using builders. For the interactive component, detail pages are requested from the master view using a proxy obtained by a widget lookup on the build context; MasterDetailFlow.of(context).
When `retainPriorEvents` is passed as true, the current behavior still limits timeline events to the timestamp after `traceEvents` is called. This can cause startup events to be missing.
This fixes it by passing null to `stopTracingAndDownloadTimeline` for the start and end time.
Related: #58430
Due to a bug in analyzer [1], some unused imports are not reported when
multiple import directives share a prefix name, and one or more are unused.
[1] https://github.com/dart-lang/sdk/issues/38784
This rolls the engine from:
965fbbed1776545ee681cb57f3fb1d0c2000bbcb to
b5f5e6332cb4987e9e38ffaa267733ec0a8705ba. A Dart SDK roll in this range
changed the format of the compileExpression RPC VMService endpoint,
necessitating a tool patch.
In google3, the Linux device is always available, and it has confused
people who run the Flutter doctor and see
"• Linux • Linux • linux-x64 • Linux" listed.
Rename the Linux device name to "Linux desktop" and the device ID to
be "linux". Make similar changes to the Windows and macOS
devices for consistency. This is also consistent with the web
devices.
The device ID change shouldn't be break -d usage since that does a
case-insensitive prefix match.
On Windows, Process.run assumes the output uses the system codepage by default. This allows specifying it in our wrapper, and sets the encoding for vswhere to UTF-8 since we're passing a flag that forces it to use UTF-8 output.
Fixes#53515
Some of the null-safety commands were missing - plumb them through. Ensure that verbose mode shows their output, and clean up the messaging around sound-null-safety.
Fixes#59769
Adds a test that validate each of the null safety supporting build commands has everything plumbed through.
https://github.com/dart-lang/coverage - 0.14.0 added the ability to be able to ignore coverage depending on comments.
// coverage:ignore-line to ignore one line.
// coverage:ignore-start and // coverage:ignore-end to ignore range of lines inclusive.
// coverage:ignore-file to ignore the whole file.
Refactors KernelCompiler and ResidentCompiler to no longer use globals (except as a fallback for g3 migration). Improves the compilation error when running flutter test on a package without a flutter_test dependency.
Updates machine mode to output trace text to stderr
A frequent request from the last Flutter developer survey was for an easier method of testing light/dark mode changes. Currently, a user needs to manually change the theme settings or adjust phone settings to see the difference. Instead we should add a toggle from the CLI, and eventually devtools/Intellij/Vscode that allows developers to override the current setting.
Fixes#59495
Adds flutter.ext.brightnessOverride service protocol which either queries the current platform brightness, or overrides it to a new value. This accepts either Brightness.light or Brightness.dark as a value.
Adds a CLI toggle b which allows the setting to be toggled manually.
Requires an update to the MediaQuery, to conditionally use a debug override when not in release mode
Failing dev/integration_tests/ui/test_driver/keyboard_resize_test.dart
Also timing out on new_gallery_ios__transition_perf
This reverts commit c7a37c72c2.
This removes a dependency from Flutter (package:collection) by copying the implementation of mergeSort into Flutter's foundation/collections.dart.
Also, removed a reference to UnmodifiableSetView from the shortcuts code by just returning a copy instead.
Updates the tooling to use the GTK embedding, rather than the GLFW embedding:
- Adds new requirements to `doctor`
- Updates the app and plugin templates to make GTK-based runners and plugins
- Stops downloading and installing the GLFW artifacts
Final part of #54860, other than cleanup.
This command was previously used by the re-entrant build scripts in xcode_backend.sh and build.gradle. These have since been refactored to use flutter assemble.
Deprecation the command in preparation for removal in a future release of flutter. The only current use is a test on HHH
Ensure that the language version of the test/web generated entrypoint matches the language version of the test file to run, or the overall package language version if no annotation is provided.
* Add instructions for updating a localized string
* gem_missing_localizations does nothing when I test this out, seems to not be required
* Explain generation of new locale strings
This install step fails if the list is empty, which is the case for projects without plugins (or Dart-only plugins, so flutter/plugins presubmits are currently broken).
The tool was setting the output preferences in a sub-context. Originally these were not injected before the arg parsers were created, though that was fixed by the lazy command creation. Once local engine is removed, the inner flutter_command Zone can be removed.
Support Microsoft Edge as a device for flutter run when web is enabled. Currently this only works on Windows, and does not include a validator for edge.
Fixes#55322
flutter analyze was unconditionally using the cached dart-sdk for analysis, and was not running with the built SDK during local engine. This broke when trying to update the analyzer for null safety, since it required us to wait for the dart change to roll into the framework first.
flutter analyze was unconditionally using the cached dart-sdk for analysis, and was not running with the built SDK during local engine. This broke when trying to update the analyzer for null safety, since it required us to wait for the dart change to roll into the framework first.
As of flutter.dev/go/engine-cpu-profiling, we collect the CPU and
Memory usage. With work being done to collect GPU usage on iOS as well.
This adds them to the timeline summary.
Fixes: https://github.com/flutter/flutter/issues/58803
This PR makes _RenderSlider not be a semantics container. This is so that the FocusableActionDetector in the Slider widget will get to aggregate the semantics information, since otherwise Talkback won't focus the slider because it thinks that the focus node doesn't have anything to say (which it doesn't but the _RenderSlider child does). If the _RenderSlider is a semantics container, then it keeps its speakable information to itself, but it isn't the Focus widget, so when the keyboard focus goes to the focus node, the accessibility focus doesn't move.
Since the _RenderSlider is always wrapped by the Slider widget, there's nothing lost in making it not be a container.
* Revert "Revert "Send text error in JSON and print in tools (#58284)" (#58872)"
This reverts commit c2d5e18cb2.
* Put streamListen in try/catch if extension events already listened for
instead of restricting profile/release mode based on whether the tool thinks the device is an emulator, restrict based on the device target architecture and the requested build mode. Notably, this enables release mode on x86_64 Android emulators, but not x86 emulators since we do not support that as an AOT target.
This does not add release mode support for simulators, since this requires us to build and upload artifacts for simulator/x86_64
* Send text error in JSON and print in tools
* Add test for error text
* Fix analysis issues
* Move streamListen to try/catch and use global.printStatus
* Extract print error fn and listen for events in web runner
* Add extension listen request to test
* Update packages/flutter_tools/lib/src/resident_runner.dart
Co-authored-by: Jonah Williams <jonahwilliams@google.com>
* Rename error parsing method
* Allow crash if listen for extension stream fails
* Add test for error and non-error extension events
* Fix formatting for TextTreeRenderer
* Use shorter message for second exceptions
* Specify types for map
* Add empty JSON for resident_web_runner test
* Move stream listen to vmservice and add vmservice test
* Fix stream type
* Move structured error log definition to vmservice
* Use correct test matcher isNot
Co-authored-by: Jonah Williams <jonahwilliams@google.com>
Current versions of the Windows desktop build files don't require a specific Windows 10 SDK version, but doctor still checks for one since vswhere doesn't allow for flexible queries. This has been a common source of issues for people setting up on Windows for the first time, because the current VS installer by default only includes a newer version of the SDK than what doctor is looking for.
This removes the vswhere SDK check, and instead uses a manual check for SDKs. Since this uses undocumented (although fairly widely used, so relatively unlikely to change) registry information, the check is non-fatal, so that builds can progress even if the SDK isn't found by doctor; in practice, it's very unlikely that someone would install the C++ Windows development workload but remove the selected-by-default SDK from the install.
Now that all requirements are default, the instructions when missing VS have been simplified so that they no longer list individual components, and instead just say to include default items.
Fixes#50487