Tags: flutter/flutter
Tags
[CP-stable][flutter_tools] Safely handle non-JSON messages in test st… …ream parsers (#192419) This pull request is created by [automatic cherry pick workflow](https://github.com/flutter/flutter/blob/main/docs/releases/Flutter-Cherrypick-Process.md#automatically-creates-a-cherry-pick-request) Please fill in the form below, and a flutter domain expert will evaluate this cherry pick request. ### Issue Link: #191898 ### Impact Description: Top crash in Flutter 3.47.1 accounting for 245 crashes (11.7% share of top crashes). When a test runner process or browser socket dumps unformatted non-JSON error output (such as dynamic library loading errors or missing snapshot warnings) directly onto the test communication stream or WebSocket, `_ChunkedJsonParser` throws an unhandled `FormatException: Unexpected character (at character 1)`, terminating the `flutter test` CLI process. ### Changelog Description: [flutter/191898] When remote test processes emit plain-text error output on all platforms, prevent flutter_tools from crashing with an unhandled FormatException. ### Workaround: None. Any test execution where a child runner or socket prints plain text instead of JSON fatal crashes the test runner CLI. ### Risk: ### Test Coverage: ### Validation Steps: Run `flutter test test/general.shard/flutter_platform_test.dart` and `flutter test test/commands.shard/hermetic/flutter_web_platform_test.dart`. Specifically, `pipeHarnessToRemote safely ignores non-JSON string and logs warning` validates that plain text received over the stream logs a warning/trace without crashing the process, and subsequent valid JSON packets are processed normally.
[CP-beta][native assets] Bump minimum iOS version from 13 to 15 (#192507 ) This pull request is created by [automatic cherry pick workflow](https://github.com/flutter/flutter/blob/main/docs/releases/Flutter-Cherrypick-Process.md#automatically-creates-a-cherry-pick-request) Please fill in the form below, and a flutter domain expert will evaluate this cherry pick request. ### Issue Link: What is the link to the issue this cherry-pick is addressing? dart-lang/native#3594 ### Impact Description: What is the impact (ex. visual jank on Samsung phones, app crash, cannot ship an iOS app)? Does it impact development (ex. flutter doctor crashes when Android Studio is installed), or the shipping of production apps (the app crashes on launch). This information is for domain experts and release engineers to understand the consequences of saying yes or no to the cherry pick. Developers cannot submit iOS apps to App Store Connect / TestFlight when using native assets compiled with -mios-version-min >= 14 (such as libraries using C++20). This impacts shipping production apps. Apple rejects the uploaded IPA with error ITMS-90208: Invalid Bundle because flutter_tools generates a framework Info.plist with MinimumOSVersion = 13.0, conflicting with the binary's higher OS requirement. ### Changelog Description: Explain this cherry pick: * In one line that is accessible to most Flutter developers. * That describes the state prior to the fix. * That includes which platforms are impacted. See [best practices](https://github.com/flutter/flutter/blob/main/docs/releases/Hotfix-Documentation-Best-Practices.md) for examples. [flutter/191964](#191964): On iOS, apps bundling native assets fail App Store submission when native libraries are compiled with deployment targets above iOS 13. ### Workaround: Is there a workaround for this issue? Manually edit Info.plist inside Runner.app/Frameworks/<name>.framework/Info.plist in the built archive to set MinimumOSVersion to 15.0, and re-sign the framework and app before uploading to App Store Connect ### Risk: What is the risk level of this cherry-pick? ### Test Coverage: Are you confident that your fix is well-tested by automated tests? ### Validation Steps: What are the steps to validate that this fix works? 1) Build an iOS app with native assets: flutter build ios --release --no-codesign. 2) Check the framework Info.plist ``` plutil -p build/ios/iphoneos/Runner.app/Frameworks/*.framework/Info.plist | grep MinimumOSVersion ``` 3)Confirm it reads "15.0" instead of "13.0"
[CP-beta]Fix Android license detection for cmdline-tools 23.0+ (#192132) This pull request is created by [automatic cherry pick workflow](https://github.com/flutter/flutter/blob/main/docs/releases/Flutter-Cherrypick-Process.md#automatically-creates-a-cherry-pick-request) Please fill in the form below, and a flutter domain expert will evaluate this cherry pick request. ### Issue Link: #191487 ### Impact Description: Android SDK Command-line Tools 23.0 deprecated `sdkmanager --licenses` in favor of the new `android` CLI. When invoked, `sdkmanager --licenses` now only outputs a deprecation notice (`Warning: The --licenses option is no longer needed.`) rather than the parseable license summary `flutter doctor` previously depended on. As a result, `flutter doctor` fails to parse license status and reports `✗ Android license status unknown.` while prompting users to run `flutter doctor --android-licenses`, which fails to resolve the issue. ### Changelog Description: [flutter/191487] When using Android SDK Command-line Tools 23.0+ for Android, flutter doctor incorrectly reports "Android license status unknown". ### Workaround: 1. Downgrade Android SDK Command-line Tools to version 22.0 via the Android Studio SDK Manager or CLI. 2. If licenses have already been accepted on disk in `<Android-SDK>/licenses/`, Android Gradle builds still succeed and the `flutter doctor` warning can be safely ignored (if the user knows to ignore). ### Risk: What is the risk level of this cherry-pick? ### Test Coverage: Are you confident that your fix is well-tested by automated tests? ### Validation Steps: 1. Ensure Android SDK Command-line Tools 23.0 is installed (verify in `$ANDROID_HOME/cmdline-tools/latest/source.properties` that `Pkg.Revision=23.0`). 2. Run `flutter doctor -v`. 3. Verify that under `Android toolchain`, it reports `• All Android licenses accepted.` instead of `✗ Android license status unknown.` 4. (Optional negative check) Temporarily rename the `$ANDROID_HOME/licenses` directory, run `flutter doctor -v`, and verify it reports `Android licenses not accepted`. Restore the directory.
PreviousNext