Skip to content

[flutter_tools] add typed enum and defaulted option descriptors - #191760

Merged
auto-submit[bot] merged 4 commits into
flutter:masterfrom
kevmoo:enum-option-descriptors
Sep 4, 2026
Merged

auto-submit[bot] merged 4 commits into
flutter:masterfrom
kevmoo:enum-option-descriptors

Conversation

@kevmoo

@kevmoo kevmoo commented Aug 25, 2026 •

Copy link
Copy Markdown
Contributor

Third step in the type-safe, declarative CLI argument refactor for flutter_tools (following #191018 and #191510).

This PR introduces typed enum option descriptors and defaulted string/enum descriptors, and migrates existing Web and Common options to use them.

Key Changes

  1. EnumOptionDescriptor<T extends Enum> & DefaultedEnumOptionDescriptor<T extends Enum> (lib/src/runner/options/option_descriptor.dart):

    • Automatically derives allowed values via values.map(...).
    • Supports nameMapper, valueParser, and automatic CliEnum mapping for allowed and allowedHelp.
    • Returns strongly-typed T? or T from getValue(), eliminating manual fromCliName() parsing and casting.
  2. DefaultedStringOptionDescriptor (lib/src/runner/options/option_descriptor.dart):

    • Requires concrete non-null defaultsTo.
    • Statically types getValue() to return non-nullable String.
    • Removes ad-hoc getValueOrDefault() helper from StringOptionDescriptor.
  3. Migration of Existing Options:

    • Migrated WebOptions.pwaStrategy from static final StringOptionDescriptor to const EnumOptionDescriptor<ServiceWorkerStrategy>.
    • Migrated CommonOptions.target from StringOptionDescriptor to const DefaultedStringOptionDescriptor.
    • Updated build_web.dart to pass getValue(WebOptions.pwaStrategy) directly without manual fromCliName() conversion.

Verification

  • Whole-package dart analyze across packages/flutter_tools: 0 issues.
  • Unit and command tests (option_descriptor_test.dart, build_info_options_bundle_test.dart, build_web_test.dart): 55/55 tests passing.

Third step in the type-safe, declarative CLI argument refactor for `flutter_tools`
(following flutter#191018 and flutter#191510).

This PR introduces typed enum option descriptors and defaulted string/enum
descriptors, and migrates existing Web and Common options to use them:

### Key Enhancements

1. **`EnumOptionDescriptor<T extends Enum>` & `DefaultedEnumOptionDescriptor<T extends Enum>`**:
   - Automatically derives allowed values via `values.map(...)`.
   - Supports `nameMapper`, `valueParser`, and automatic `CliEnum` mapping for `allowed` and `allowedHelp`.
   - Returns strongly-typed `T?` / `T` instances from `getValue()`.

2. **`DefaultedStringOptionDescriptor`**:
   - Requires concrete non-null `defaultsTo`.
   - Statically types `getValue()` to return non-nullable `String`.

3. **Migration of Existing Options**:
   - Migrated `WebOptions.pwaStrategy` to `const EnumOptionDescriptor<ServiceWorkerStrategy>`.
   - Migrated `CommonOptions.target` to `const DefaultedStringOptionDescriptor`.
   - Removed ad-hoc `getValueOrDefault()` helper from `StringOptionDescriptor`.

### Testing & Verification
- Added comprehensive unit tests in `test/general.shard/runner/options/option_descriptor_test.dart`.
- `dart analyze`: **0 issues**.
- Test suite (`option_descriptor_test.dart`, `build_info_options_bundle_test.dart`, `build_web_test.dart`): **55/55 passed**.
@github-actions github-actions Bot added the tool Affects the "flutter" command-line tool. See also t: labels. label Aug 25, 2026
@kevmoo
kevmoo marked this pull request as ready for review August 25, 2026 23:17

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces new option descriptors, including DefaultedStringOptionDescriptor, EnumOptionDescriptor, and DefaultedEnumOptionDescriptor, to handle default values and enum-based CLI options. It updates the pwa-strategy option to use the new EnumOptionDescriptor and adds comprehensive unit tests. Feedback suggests refactoring EnumOptionDescriptor and DefaultedEnumOptionDescriptor to inherit from a shared private base class to reduce code duplication and improve maintainability.

@harryterkelsen harryterkelsen left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mostly LGTM but agree with gemini about the code duplication between the default and optional enum OptionDescriptors

@kevmoo

kevmoo commented Aug 25, 2026

Copy link
Copy Markdown
Contributor Author

@harryterkelsen - done!

@kevmoo

kevmoo commented Aug 28, 2026

Copy link
Copy Markdown
Contributor Author

Friendly ping!

bkonyi
bkonyi previously approved these changes Aug 28, 2026

@bkonyi bkonyi left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@kevmoo kevmoo added autosubmit Merge PR when tree becomes green via auto submit App CICD Run CI/CD labels Aug 28, 2026
@auto-submit auto-submit Bot removed the autosubmit Merge PR when tree becomes green via auto submit App label Aug 31, 2026
@auto-submit

auto-submit Bot commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

autosubmit label was removed for flutter/flutter/191760, because - The status or check suite ci.yaml validation has failed. Please fix the issues identified (or deflake) before re-applying this label.

@kevmoo
kevmoo requested a review from jtmcdole as a code owner August 31, 2026 18:11
@github-actions github-actions Bot added a: tests "flutter test", flutter_test, or one of our tests framework flutter/packages/flutter repository. See also f: labels. f: scrolling Viewports, list views, slivers, etc. f: routes Navigator, Router, and related APIs. labels Aug 31, 2026
@kevmoo kevmoo added the autosubmit Merge PR when tree becomes green via auto submit App label Aug 31, 2026
@github-actions github-actions Bot removed a: tests "flutter test", flutter_test, or one of our tests framework flutter/packages/flutter repository. See also f: labels. f: scrolling Viewports, list views, slivers, etc. f: routes Navigator, Router, and related APIs. labels Aug 31, 2026
Comment thread packages/flutter_tools/lib/src/web/web_options.dart
@kevmoo

kevmoo commented Sep 2, 2026

Copy link
Copy Markdown
Contributor Author

@bkonyi or @harryterkelsen – need another nod. sorry!

@kevmoo

kevmoo commented Sep 3, 2026

Copy link
Copy Markdown
Contributor Author

🙏

@kevmoo kevmoo added autosubmit Merge PR when tree becomes green via auto submit App and removed autosubmit Merge PR when tree becomes green via auto submit App labels Sep 4, 2026
@auto-submit
auto-submit Bot added this pull request to the merge queue Sep 4, 2026
Merged via the queue into flutter:master with commit f084d1e Sep 4, 2026
24 checks passed
@flutter-dashboard flutter-dashboard Bot removed the autosubmit Merge PR when tree becomes green via auto submit App label Sep 4, 2026
@kevmoo
kevmoo deleted the enum-option-descriptors branch September 4, 2026 02:37
auto-submit Bot pushed a commit to flutter/packages that referenced this pull request Sep 4, 2026
…12760)

Manual roll Flutter from 70797e15325e to 5a6cfa7f3d26 (52 revisions)

Manual roll requested by [email protected]

flutter/flutter@70797e1...5a6cfa7

2026-09-04 [email protected] [tool] Migrate ScreenshotCommand to modular dependency injection (flutter/flutter#190767)
2026-09-04 [email protected] Roll Skia from 8fce167bdded to 93ac1e630d1d (3 revisions) (flutter/flutter#192306)
2026-09-04 [email protected] Add iOS Universal Link integration test (Simulator) (flutter/flutter#191443)
2026-09-04 [email protected] [AGP 9.1.0 Migration #5] Delete getLegacyAndroidExtension and migrate NDK fallback to public DSL (flutter/flutter#192116)
2026-09-04 [email protected] Reland "[tool_tests] Remove bringup from Windows tool_tests_commands_2_2" (#191732) (flutter/flutter#191802)
2026-09-04 [email protected] [flutter_tools] Fix unhandled DebugAdapterException on early process termination (flutter/flutter#192294)
2026-09-04 [email protected] Roll Packages from f9b3954 to 9af9c60 (4 revisions) (flutter/flutter#192292)
2026-09-04 [email protected] Roll Skia from 2e3f7e07eee6 to 8fce167bdded (5 revisions) (flutter/flutter#192283)
2026-09-04 [email protected] Roll Fuchsia Linux SDK from GTZNkoIR_WegRPWgL... to FgDQeF6jb1dVRVh3K... (flutter/flutter#192276)
2026-09-04 [email protected] Roll Skia from b6b00df360e5 to 2e3f7e07eee6 (2 revisions) (flutter/flutter#192275)
2026-09-04 [email protected] [iOS] TextField should support typing accented words with external keyboard (flutter/flutter#191062)
2026-09-04 [email protected] Roll Skia from 1f68c0b16f17 to b6b00df360e5 (7 revisions) (flutter/flutter#192269)
2026-09-04 [email protected] [flutter_tools] add typed enum and defaulted option descriptors (flutter/flutter#191760)
2026-09-04 [email protected] Roll Dart SDK from c2edc382a4f8 to 5501d02b583d (1 revision) (flutter/flutter#192263)
2026-09-04 [email protected] [Linux] Use fences to synchronize frames between OpenGL contexts (flutter/flutter#192098)
2026-09-03 [email protected] Defer semantics geometry updates for blocked branches (flutter/flutter#192146)
2026-09-03 [email protected] Roll Skia from 8d3e197531c6 to 1f68c0b16f17 (8 revisions) (flutter/flutter#192244)
2026-09-03 [email protected] Fix DeleteSurrounding splitting UTF-16 surrogate pairs (flutter/flutter#190514)
2026-09-03 [email protected] Remove no-shuffle from progress indicator test (flutter/flutter#186655)
2026-09-03 [email protected] [material] Remove unused parameters from constructors of generic test class (flutter/flutter#191764)
2026-09-03 [email protected] Handle linear and radial gradients in UberSDF (re-implement after fix) (flutter/flutter#192124)
2026-09-03 [email protected] Roll Dart SDK from fcbfb64f42a1 to c2edc382a4f8 (2 revisions) (flutter/flutter#192240)
2026-09-03 [email protected] Fix parsing of --enable-hcpp-and-surface-control switch and add --no-enable-hcpp tests (flutter/flutter#192202)
2026-09-03 [email protected] Fix issue where shapes rendered with gradient+blur+rotation end up incorrectly cut off (flutter/flutter#192136)
2026-09-03 [email protected] Fix sibling nodes crash under MergeSemantics (flutter/flutter#191587)
2026-09-03 [email protected] Makes backdrop groups operate on the union. (flutter/flutter#191838)
2026-09-03 [email protected] Roll Skia from 008936396810 to 8d3e197531c6 (1 revision) (flutter/flutter#192236)
2026-09-03 [email protected] [docs] Remove superseded AI rules for Flutter (flutter/flutter#192185)
2026-09-03 [email protected] Collect analytics about SwiftPM errors and warnings (flutter/flutter#191746)
2026-09-03 [email protected] Roll Packages from 18fe786 to f9b3954 (7 revisions) (flutter/flutter#192235)
2026-09-03 [email protected] [Linux] Remove frame sharing between OpenGL contexts (flutter/flutter#192150)
2026-09-03 [email protected] Roll Dart SDK from cf79067a1e44 to fcbfb64f42a1 (1 revision) (flutter/flutter#192228)
2026-09-03 [email protected] Roll Skia from 731fe9af4c0b to 008936396810 (3 revisions) (flutter/flutter#192225)
2026-09-03 [email protected] Roll Dart SDK from 700ab60bfe53 to cf79067a1e44 (2 revisions) (flutter/flutter#192219)
2026-09-03 [email protected] Roll Skia from 823f82e18177 to 731fe9af4c0b (5 revisions) (flutter/flutter#192217)
2026-09-03 [email protected] Fixes OverlayPortal semantics bounds corruption (flutter/flutter#192139)
2026-09-03 [email protected] Roll Fuchsia Linux SDK from idslm9FikVLy2K_A-... to GTZNkoIR_WegRPWgL... (flutter/flutter#192215)
2026-09-03 [email protected] Roll Fuchsia Test Scripts from u_fSMsPU22VvUsvSo... to VObjlh3xw2P9sEbC_... (flutter/flutter#192212)
2026-09-03 [email protected] Roll Skia from ae22da2e8308 to 823f82e18177 (13 revisions) (flutter/flutter#192209)
2026-09-02 [email protected] Expose skipTraversal in FocusableActionDetector (flutter/flutter#191308)
2026-09-02 [email protected] Add `IsProgram` mock method to `MockGLESImpl`, use it in `BufferBindingsGLESTest` (flutter/flutter#192196)
2026-09-02 [email protected] Fix nested scroll view fling crash (flutter/flutter#191130)
2026-09-02 [email protected] Fix TabBarView/PageView edge auto-scroll during mouse text selection (flutter/flutter#189544)
2026-09-02 [email protected] Bypass gamma correction when alpha >= 1.0 (flutter/flutter#192193)
...
pull Bot pushed a commit to ZainCheung/flutter that referenced this pull request Sep 8, 2026
…criptor (flutter#192307)

Migrates `createDebuggingOptions()` in `RunCommandBase`
(`lib/src/commands/run.dart`) and associated option registration helpers
in `FlutterCommand` (`lib/src/runner/flutter_command.dart`) to typed
`OptionDescriptor` instances, continuing the CLI argument architecture
modernization started in flutter#191018, flutter#191510, and flutter#191760.

## Summary of Changes

* **Typed Debugging Option Descriptors (`DebuggingOptionDescriptors` in
`common_options.dart`)**:
* Defined 35+ strongly-typed descriptors covering engine flags
(`enableImpeller`, `enableFlutterGpu`, `enableVulkanValidation`,
`enableEmbedderApi`, `enableHcpp`), tracing/profiling (`traceStartup`,
`traceSystrace`, `traceToFile`, `endlessTraceBuffer`,
`profileMicrotasks`, `traceSkia`, `traceAllowlist`,
`traceSkiaAllowlist`, `enableDartProfiling`, `profileStartup`,
`cacheStartupProfile`, `verboseSystemLogs`, `purgePersistentCache`), VM
service/DevTools/DDS (`dds`, `ddsPort`, `disableDds`, `enableDevTools`,
`devToolsServerAddress`, `vmserviceOutFile`, `disableServiceAuthCodes`,
`disableServiceOriginCheck`, `startPaused`, `dartFlags`, `ipv6`), and
runner configuration (`route`, `enableSoftwareRendering`,
`skiaDeterministicRendering`, `dartEntrypointArgs`, `uninstallFirst`,
`iosProfileDebugger`, `useTestFonts`, `adbLogFiltering`, `testFlag`).
* **Web Server & Debugging Descriptors (`WebOptions` in
`web_options.dart`)**:
* Added typed descriptors for `webHeader`, `webHostname`, `webPort`,
`webTlsCertPath`, `webTlsCertKeyPath`, `webServerDebugProtocol`,
`webServerDebugBackendProtocol`, `webServerDebugInjectedClientProtocol`,
`webAllowExposeUrl`, `webRunHeadless`, `webBrowserDebugPort`,
`webEnableExpressionEvaluation`, `webLaunchUrl`, `webBrowserFlags`, and
`crossOriginIsolation`.
* **`ArgParserDescriptorExtension` & Automatic `Expando` Registry
(`option_descriptor.dart`)**:
* Added `addDescriptor` / `addDescriptors` extension methods on
`ArgParser` for concise option registration.
* Replaced explicit `Map<String, OptionDescriptor>? registry` parameter
plumbing across `OptionDescriptor.addTo()`, `OptionBundle.register()`,
and `FlutterCommand._optionRegistry` with an internal
`Expando<Map<String, OptionDescriptor<Object?>>>` on `ArgParser`,
ensuring automatic diamond-bundle de-duplication and conflict detection
across all registration paths.
* **Tri-State `bool?` Semantics**:
* Used `NullableFlagOptionDescriptor` (`defaultsTo: null`) for flags
whose omitted state is semantically distinct from `false`
(`enable-impeller`, `enable-flutter-gpu`, `enable-hcpp`,
`cross-origin-isolation`, `ios-profile-debugger`), allowing
`getValue(...)` to preserve `bool?` without manual string lookups.
* **Eliminated Untyped Lookups in `createDebuggingOptions()`**:
* Replaced 35+ untyped `argParser.options.containsKey('...')`,
`boolArg('...')`, `stringArg('...')`, and `stringsArg('...')` lookups in
`RunCommandBase.createDebuggingOptions()`, `webDevServerConfigCore()`,
and `FlutterCommand` helpers (`usesWebOptions`, `addDdsOptions`,
`addDevToolsOptions`, `explicitEnableHcpp`, `ddsPort`,
`devToolsServerAddress`) with type-safe `getValue(...)`,
`wasParsed(...)`, and `hasOption(...)` calls.

## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide], including [Features
we expect every widget to implement].
- [x] I signed the [CLA].
- [x] I listed at least one issue that this PR fixes in the description
above.
- [x] I updated/added relevant documentation (doc comments with `///`).
- [x] I added new tests to check the change I am making, or this PR is
[test-exempt].
- [x] All existing and new tests are passing.
victorsanni pushed a commit to victorsanni/packages that referenced this pull request Sep 9, 2026
…lutter#12760)

Manual roll Flutter from 70797e15325e to 5a6cfa7f3d26 (52 revisions)

Manual roll requested by [email protected]

flutter/flutter@70797e1...5a6cfa7

2026-09-04 [email protected] [tool] Migrate ScreenshotCommand to modular dependency injection (flutter/flutter#190767)
2026-09-04 [email protected] Roll Skia from 8fce167bdded to 93ac1e630d1d (3 revisions) (flutter/flutter#192306)
2026-09-04 [email protected] Add iOS Universal Link integration test (Simulator) (flutter/flutter#191443)
2026-09-04 [email protected] [AGP 9.1.0 Migration flutter#5] Delete getLegacyAndroidExtension and migrate NDK fallback to public DSL (flutter/flutter#192116)
2026-09-04 [email protected] Reland "[tool_tests] Remove bringup from Windows tool_tests_commands_2_2" (#191732) (flutter/flutter#191802)
2026-09-04 [email protected] [flutter_tools] Fix unhandled DebugAdapterException on early process termination (flutter/flutter#192294)
2026-09-04 [email protected] Roll Packages from f9b3954 to 9af9c60 (4 revisions) (flutter/flutter#192292)
2026-09-04 [email protected] Roll Skia from 2e3f7e07eee6 to 8fce167bdded (5 revisions) (flutter/flutter#192283)
2026-09-04 [email protected] Roll Fuchsia Linux SDK from GTZNkoIR_WegRPWgL... to FgDQeF6jb1dVRVh3K... (flutter/flutter#192276)
2026-09-04 [email protected] Roll Skia from b6b00df360e5 to 2e3f7e07eee6 (2 revisions) (flutter/flutter#192275)
2026-09-04 [email protected] [iOS] TextField should support typing accented words with external keyboard (flutter/flutter#191062)
2026-09-04 [email protected] Roll Skia from 1f68c0b16f17 to b6b00df360e5 (7 revisions) (flutter/flutter#192269)
2026-09-04 [email protected] [flutter_tools] add typed enum and defaulted option descriptors (flutter/flutter#191760)
2026-09-04 [email protected] Roll Dart SDK from c2edc382a4f8 to 5501d02b583d (1 revision) (flutter/flutter#192263)
2026-09-04 [email protected] [Linux] Use fences to synchronize frames between OpenGL contexts (flutter/flutter#192098)
2026-09-03 [email protected] Defer semantics geometry updates for blocked branches (flutter/flutter#192146)
2026-09-03 [email protected] Roll Skia from 8d3e197531c6 to 1f68c0b16f17 (8 revisions) (flutter/flutter#192244)
2026-09-03 [email protected] Fix DeleteSurrounding splitting UTF-16 surrogate pairs (flutter/flutter#190514)
2026-09-03 [email protected] Remove no-shuffle from progress indicator test (flutter/flutter#186655)
2026-09-03 [email protected] [material] Remove unused parameters from constructors of generic test class (flutter/flutter#191764)
2026-09-03 [email protected] Handle linear and radial gradients in UberSDF (re-implement after fix) (flutter/flutter#192124)
2026-09-03 [email protected] Roll Dart SDK from fcbfb64f42a1 to c2edc382a4f8 (2 revisions) (flutter/flutter#192240)
2026-09-03 [email protected] Fix parsing of --enable-hcpp-and-surface-control switch and add --no-enable-hcpp tests (flutter/flutter#192202)
2026-09-03 [email protected] Fix issue where shapes rendered with gradient+blur+rotation end up incorrectly cut off (flutter/flutter#192136)
2026-09-03 [email protected] Fix sibling nodes crash under MergeSemantics (flutter/flutter#191587)
2026-09-03 [email protected] Makes backdrop groups operate on the union. (flutter/flutter#191838)
2026-09-03 [email protected] Roll Skia from 008936396810 to 8d3e197531c6 (1 revision) (flutter/flutter#192236)
2026-09-03 [email protected] [docs] Remove superseded AI rules for Flutter (flutter/flutter#192185)
2026-09-03 [email protected] Collect analytics about SwiftPM errors and warnings (flutter/flutter#191746)
2026-09-03 [email protected] Roll Packages from 18fe786 to f9b3954 (7 revisions) (flutter/flutter#192235)
2026-09-03 [email protected] [Linux] Remove frame sharing between OpenGL contexts (flutter/flutter#192150)
2026-09-03 [email protected] Roll Dart SDK from cf79067a1e44 to fcbfb64f42a1 (1 revision) (flutter/flutter#192228)
2026-09-03 [email protected] Roll Skia from 731fe9af4c0b to 008936396810 (3 revisions) (flutter/flutter#192225)
2026-09-03 [email protected] Roll Dart SDK from 700ab60bfe53 to cf79067a1e44 (2 revisions) (flutter/flutter#192219)
2026-09-03 [email protected] Roll Skia from 823f82e18177 to 731fe9af4c0b (5 revisions) (flutter/flutter#192217)
2026-09-03 [email protected] Fixes OverlayPortal semantics bounds corruption (flutter/flutter#192139)
2026-09-03 [email protected] Roll Fuchsia Linux SDK from idslm9FikVLy2K_A-... to GTZNkoIR_WegRPWgL... (flutter/flutter#192215)
2026-09-03 [email protected] Roll Fuchsia Test Scripts from u_fSMsPU22VvUsvSo... to VObjlh3xw2P9sEbC_... (flutter/flutter#192212)
2026-09-03 [email protected] Roll Skia from ae22da2e8308 to 823f82e18177 (13 revisions) (flutter/flutter#192209)
2026-09-02 [email protected] Expose skipTraversal in FocusableActionDetector (flutter/flutter#191308)
2026-09-02 [email protected] Add `IsProgram` mock method to `MockGLESImpl`, use it in `BufferBindingsGLESTest` (flutter/flutter#192196)
2026-09-02 [email protected] Fix nested scroll view fling crash (flutter/flutter#191130)
2026-09-02 [email protected] Fix TabBarView/PageView edge auto-scroll during mouse text selection (flutter/flutter#189544)
2026-09-02 [email protected] Bypass gamma correction when alpha >= 1.0 (flutter/flutter#192193)
...
victorsanni pushed a commit to victorsanni/packages that referenced this pull request Sep 9, 2026
…lutter#12760)

Manual roll Flutter from 70797e15325e to 5a6cfa7f3d26 (52 revisions)

Manual roll requested by [email protected]

flutter/flutter@70797e1...5a6cfa7

2026-09-04 [email protected] [tool] Migrate ScreenshotCommand to modular dependency injection (flutter/flutter#190767)
2026-09-04 [email protected] Roll Skia from 8fce167bdded to 93ac1e630d1d (3 revisions) (flutter/flutter#192306)
2026-09-04 [email protected] Add iOS Universal Link integration test (Simulator) (flutter/flutter#191443)
2026-09-04 [email protected] [AGP 9.1.0 Migration flutter#5] Delete getLegacyAndroidExtension and migrate NDK fallback to public DSL (flutter/flutter#192116)
2026-09-04 [email protected] Reland "[tool_tests] Remove bringup from Windows tool_tests_commands_2_2" (#191732) (flutter/flutter#191802)
2026-09-04 [email protected] [flutter_tools] Fix unhandled DebugAdapterException on early process termination (flutter/flutter#192294)
2026-09-04 [email protected] Roll Packages from f9b3954 to 9af9c60 (4 revisions) (flutter/flutter#192292)
2026-09-04 [email protected] Roll Skia from 2e3f7e07eee6 to 8fce167bdded (5 revisions) (flutter/flutter#192283)
2026-09-04 [email protected] Roll Fuchsia Linux SDK from GTZNkoIR_WegRPWgL... to FgDQeF6jb1dVRVh3K... (flutter/flutter#192276)
2026-09-04 [email protected] Roll Skia from b6b00df360e5 to 2e3f7e07eee6 (2 revisions) (flutter/flutter#192275)
2026-09-04 [email protected] [iOS] TextField should support typing accented words with external keyboard (flutter/flutter#191062)
2026-09-04 [email protected] Roll Skia from 1f68c0b16f17 to b6b00df360e5 (7 revisions) (flutter/flutter#192269)
2026-09-04 [email protected] [flutter_tools] add typed enum and defaulted option descriptors (flutter/flutter#191760)
2026-09-04 [email protected] Roll Dart SDK from c2edc382a4f8 to 5501d02b583d (1 revision) (flutter/flutter#192263)
2026-09-04 [email protected] [Linux] Use fences to synchronize frames between OpenGL contexts (flutter/flutter#192098)
2026-09-03 [email protected] Defer semantics geometry updates for blocked branches (flutter/flutter#192146)
2026-09-03 [email protected] Roll Skia from 8d3e197531c6 to 1f68c0b16f17 (8 revisions) (flutter/flutter#192244)
2026-09-03 [email protected] Fix DeleteSurrounding splitting UTF-16 surrogate pairs (flutter/flutter#190514)
2026-09-03 [email protected] Remove no-shuffle from progress indicator test (flutter/flutter#186655)
2026-09-03 [email protected] [material] Remove unused parameters from constructors of generic test class (flutter/flutter#191764)
2026-09-03 [email protected] Handle linear and radial gradients in UberSDF (re-implement after fix) (flutter/flutter#192124)
2026-09-03 [email protected] Roll Dart SDK from fcbfb64f42a1 to c2edc382a4f8 (2 revisions) (flutter/flutter#192240)
2026-09-03 [email protected] Fix parsing of --enable-hcpp-and-surface-control switch and add --no-enable-hcpp tests (flutter/flutter#192202)
2026-09-03 [email protected] Fix issue where shapes rendered with gradient+blur+rotation end up incorrectly cut off (flutter/flutter#192136)
2026-09-03 [email protected] Fix sibling nodes crash under MergeSemantics (flutter/flutter#191587)
2026-09-03 [email protected] Makes backdrop groups operate on the union. (flutter/flutter#191838)
2026-09-03 [email protected] Roll Skia from 008936396810 to 8d3e197531c6 (1 revision) (flutter/flutter#192236)
2026-09-03 [email protected] [docs] Remove superseded AI rules for Flutter (flutter/flutter#192185)
2026-09-03 [email protected] Collect analytics about SwiftPM errors and warnings (flutter/flutter#191746)
2026-09-03 [email protected] Roll Packages from 18fe786 to f9b3954 (7 revisions) (flutter/flutter#192235)
2026-09-03 [email protected] [Linux] Remove frame sharing between OpenGL contexts (flutter/flutter#192150)
2026-09-03 [email protected] Roll Dart SDK from cf79067a1e44 to fcbfb64f42a1 (1 revision) (flutter/flutter#192228)
2026-09-03 [email protected] Roll Skia from 731fe9af4c0b to 008936396810 (3 revisions) (flutter/flutter#192225)
2026-09-03 [email protected] Roll Dart SDK from 700ab60bfe53 to cf79067a1e44 (2 revisions) (flutter/flutter#192219)
2026-09-03 [email protected] Roll Skia from 823f82e18177 to 731fe9af4c0b (5 revisions) (flutter/flutter#192217)
2026-09-03 [email protected] Fixes OverlayPortal semantics bounds corruption (flutter/flutter#192139)
2026-09-03 [email protected] Roll Fuchsia Linux SDK from idslm9FikVLy2K_A-... to GTZNkoIR_WegRPWgL... (flutter/flutter#192215)
2026-09-03 [email protected] Roll Fuchsia Test Scripts from u_fSMsPU22VvUsvSo... to VObjlh3xw2P9sEbC_... (flutter/flutter#192212)
2026-09-03 [email protected] Roll Skia from ae22da2e8308 to 823f82e18177 (13 revisions) (flutter/flutter#192209)
2026-09-02 [email protected] Expose skipTraversal in FocusableActionDetector (flutter/flutter#191308)
2026-09-02 [email protected] Add `IsProgram` mock method to `MockGLESImpl`, use it in `BufferBindingsGLESTest` (flutter/flutter#192196)
2026-09-02 [email protected] Fix nested scroll view fling crash (flutter/flutter#191130)
2026-09-02 [email protected] Fix TabBarView/PageView edge auto-scroll during mouse text selection (flutter/flutter#189544)
2026-09-02 [email protected] Bypass gamma correction when alpha >= 1.0 (flutter/flutter#192193)
...
flutter-zl pushed a commit to flutter-zl/flutter that referenced this pull request Oct 8, 2026
…lutter#193323)

Migrate `BuildLinuxCommand` (`build linux`) and `BuildWindowsCommand`
(`build windows`) to typed `OptionDescriptor`s and `OptionBundle`s
(following flutter#191018, flutter#191510, flutter#191760, flutter#192307, flutter#192455, flutter#192524, and
flutter#192818):

- Add `DesktopBuildOptionsBundle` in `common_options.dart`,
encapsulating `CommonBuildOptionsBundle`, `BuildModeOptionsBundle`,
`DartCompileOptionsBundle`, `BuildInfoOptions.flavor`, `splitDebugInfo`,
`obfuscate`, `extraFrontEndOptions`, `extraGenSnapshotOptions`,
`performanceMeasurementFile`, `analyzeSize`, `codeSizeDirectory`,
`trackWidgetCreation`, and `configOnly`.
- Migrate `BuildLinuxCommand` (`build_linux.dart`) to
`DesktopBuildOptionsBundle`,
`DefaultedEnumOptionDescriptor<TargetPlatform>`
(`_targetPlatformOption`), and `DefaultedStringOptionDescriptor`
(`_targetSysroot`), replacing untyped `boolArg('config-only')`,
`stringArg('target-platform')!`, and `stringArg('target-sysroot')!`
queries.
- Migrate `BuildWindowsCommand` (`build_windows.dart`) to
`DesktopBuildOptionsBundle` and
`getValue(DesktopBuildOptionsBundle.configOnly)`.
- Delete the obsolete `FlutterCommand.addCommonDesktopBuildOptions`
helper method from `flutter_command.dart` (no remaining callers in
`flutter_tools`).

## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide], including [Features
we expect every widget to implement].
- [x] I signed the [CLA].
- [ ] I listed at least one issue that this PR fixes in the description
above.
- [x] I updated/added relevant documentation (doc comments with `///`).
- [x] I added new tests to check the change I am making, or this PR is
[test-exempt].
- [x] I followed the [breaking change policy] and added [Data Driven
Fixes] where supported.
- [x] All existing and new tests are passing.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CICD Run CI/CD tool Affects the "flutter" command-line tool. See also t: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants