[material_ui] Batch release - #12423
Conversation
There was a problem hiding this comment.
Code Review
This pull request updates the material_ui package to version 0.0.3+1, adding changelog entries for replacing unresolvable doc imports and adding a main.dart example, while removing temporary changelog files. Feedback suggests correcting a grammatical error in the changelog text from 'reference' to 'references'.
| - Added a main.dart example for the Pub "Example" tab that reference a curated | ||
| list of existing examples. |
There was a problem hiding this comment.
There is a minor grammatical issue in this changelog entry. "a main.dart example... that reference" should be "that references" to agree with the singular subject "example".
| - Added a main.dart example for the Pub "Example" tab that reference a curated | |
| list of existing examples. | |
| - Added a main.dart example for the Pub "Example" tab that references a curated | |
| list of existing examples. |
|
autosubmit label was removed for flutter/packages/12423, because - The status or check suite Dashboard Checks has failed. Please fix the issues identified (or deflake) before re-applying this label. |
- Unblocks #12423 Fixes a Pub version solver failure during release PR testing (`make-deps-path-based`) for co-dependent packages (specifically `material_ui` and `cupertino_ui`). When creating a release PR for `material_ui` (e.g., `release-material_ui-0.0.3+1`), the `make-deps-path-based` CI step failed during `flutter test` on `packages/cupertino_ui` with the following Pub version solver error: ``` Resolving dependencies in `./example`... Because every version of material_ui from path depends on cupertino_ui from hosted and cupertino_ui_examples depends on cupertino_ui from path, material_ui from path is forbidden. So, because cupertino_ui_examples depends on material_ui from path, version solving failed. Failed to update packages. ``` `material_ui` and `cupertino_ui` share an asymmetric co-dependency in the repository: - **`material_ui`** has a **direct dependency** on `cupertino_ui` (`dependencies: cupertino_ui: ^0.0.3`). - **`cupertino_ui`** has a **dev dependency** on `material_ui` (`dev_dependencies: material_ui: ^0.0.2`). When `make-deps-path-based --target-dependencies=material_ui` runs: 1. `make-deps-path-based` adds `dependency_overrides: material_ui: {path: ../material_ui}` to `cupertino_ui/pubspec.yaml` and `cupertino_ui/example/pubspec.yaml`. 2. `cupertino_ui/example` depends directly on `cupertino_ui` (`path: ..`). 3. `material_ui` (from `path`) depends on `cupertino_ui: ^0.0.3` (from hosted `pub.dev`). 4. Without `cupertino_ui` in `cupertino_ui/example`'s `dependency_overrides`, Pub detects `cupertino_ui` sourced from **`path`** (in `cupertino_ui_examples`) and **`hosted`** (in `material_ui`), causing Pub's version solver to reject the resolution graph. Updated `make-deps-path-based` (`script/tool/lib/src/make_deps_path_based_command.dart`): When `_addDependencyOverridesIfNecessary` recursively updates example apps of a package (`for (final RepositoryPackage example in package.getExamples())`), it now explicitly includes the parent `package` itself in the local package mapping and `additionalPackagesToOverride`. This ensures `cupertino_ui/example/pubspec.yaml` receives a path override for its parent package (`dependency_overrides: cupertino_ui: {path: ...}`) alongside the target package override (`material_ui: {path: ...}`). Consequently, Pub solver resolves both local path dependencies cleanly without requiring recursive dependency expansion (thereby preserving the safety net of `--target-dependencies`). --- #### Why `cupertino_ui` Has a `dev_dependency` on `material_ui` `cupertino_ui` declares `material_ui` in its `dev_dependencies` because multiple files across `cupertino_ui/lib/src/` (e.g., `text_field.dart`, `dialog.dart`, `scrollbar.dart`, `theme.dart`) use Dart `@docImport` directives referencing Material design widgets in public API documentation: ```dart /// @DocImport 'package:material_ui/material_ui.dart'; ``` Per Dart doc guidelines, packages referenced in `@docImport` must be declared in `dev_dependencies` so static analysis and `dartdoc` can resolve the cross-referenced symbols. --- #### Didn't we fix this last week? - **Aug 4, 09:06 AM (`material_ui 0.0.3` release #12352)**: Both packages still used Dart Workspaces (`resolution: workspace`). Under Dart Workspaces, Pub dependency resolution was handled at the top-level workspace root, hiding the Pub solver conflict. - **Aug 4, 12:44 PM (PR #12351)**: PR #12351 landed to unblock `cupertino_ui 0.0.3` by removing Dart workspaces from `cupertino_ui` and `material_ui`. - When releasing **`cupertino_ui`** (`targetDependencies=cupertino_ui`), `material_ui` got path overrides for `cupertino_ui`. Since `cupertino_ui` didn't depend on a third package pulling hosted `cupertino_ui`, `cupertino_ui`'s release succeeded. - However, when releasing **`material_ui`** (`targetDependencies=material_ui`), `material_ui`'s direct dependency on `cupertino_ui` caused `cupertino_ui/example` to fail. - **Aug 10 (`material_ui 0.0.3+1` release #12423)**: This was the first release attempt of `material_ui` since Dart workspaces were removed, exposing the non-workspace Pub solver requirement. ## Pre-Review Checklist **Note**: The Flutter team is currently trialing the use of [Gemini Code Assist for GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code). Comments from the `gemini-code-assist` bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed. [^1]: Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling.
|
Closing to rerty |
This PR was created automatically to batch release the
material_ui.