Make sure that a FlutterLogo doesn't crash in 0x0 environment#180617
Merged
auto-submit[bot] merged 1 commit intoflutter:masterfrom Jan 12, 2026
Merged
Make sure that a FlutterLogo doesn't crash in 0x0 environment#180617auto-submit[bot] merged 1 commit intoflutter:masterfrom
auto-submit[bot] merged 1 commit intoflutter:masterfrom
Conversation
Contributor
There was a problem hiding this comment.
Code Review
This pull request adds a regression test for the FlutterLogo widget. The test verifies that the widget does not crash when rendered in a zero-sized area by placing it within a SizedBox.shrink(). My review includes a suggestion to simplify the test's widget tree for conciseness. The provided changes only contain the test addition, and not the associated fix for the crash.
| await tester.pumpWidget( | ||
| const Directionality( | ||
| textDirection: TextDirection.ltr, | ||
| child: Center(child: SizedBox.shrink(child: FlutterLogo())), |
Contributor
There was a problem hiding this comment.
The Center widget is redundant here. SizedBox.shrink() already constrains its child to a 0x0 size, so the Center widget has no effect on the layout of the FlutterLogo. Removing it will make the test's widget tree more minimal and focused on the specific scenario being tested.
child: SizedBox.shrink(child: FlutterLogo()),
victorsanni
approved these changes
Jan 7, 2026
dkwingsmt
approved these changes
Jan 12, 2026
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jan 12, 2026
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jan 12, 2026
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jan 12, 2026
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jan 12, 2026
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jan 12, 2026
auto-submit bot
pushed a commit
to flutter/packages
that referenced
this pull request
Jan 12, 2026
flutter/flutter@3134be8...d81cd3e 2026-01-12 47866232+chunhtai@users.noreply.github.com Migrate doc and code to use sendAnnounce (flutter/flutter#180776) 2026-01-12 engine-flutter-autoroll@skia.org Roll Packages from 51fe1d9 to e57e7f4 (3 revisions) (flutter/flutter#180846) 2026-01-12 dixita0607@users.noreply.github.com Fix: Allow dartpad embed clipboard-write permission for "Copy to clipboard" functionality (flutter/flutter#178057) 2026-01-12 engine-flutter-autoroll@skia.org Roll Dart SDK from 87fbfd5381b6 to 42fd9ef68c1a (1 revision) (flutter/flutter#180836) 2026-01-12 engine-flutter-autoroll@skia.org Roll Skia from aefdde600f1e to 487a9943210b (3 revisions) (flutter/flutter#180835) 2026-01-12 goderbauer@google.com Bump ffigen (flutter/flutter#180507) 2026-01-12 engine-flutter-autoroll@skia.org Roll Skia from d42a43daa6cf to aefdde600f1e (1 revision) (flutter/flutter#180829) 2026-01-12 ahmedsameha1@gmail.com Make sure that a LongPressDraggable doesn't crash in 0x0 environment (flutter/flutter#180408) 2026-01-12 ahmedsameha1@gmail.com Make sure that a FlutterLogo doesn't crash in 0x0 environment (flutter/flutter#180617) 2026-01-12 engine-flutter-autoroll@skia.org Roll Fuchsia Linux SDK from T_HOCpDjLgzi1SUMq... to VYeyMPe1lyCtlcl-V... (flutter/flutter#180825) 2026-01-11 engine-flutter-autoroll@skia.org Roll Skia from f39cc645b1dd to d42a43daa6cf (2 revisions) (flutter/flutter#180819) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages Please CC stuartmorgan@google.com,tarrinneal@google.com on the revert to ensure that a human is aware of the problem. To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
ivan-vanyusho
pushed a commit
to ivan-vanyusho/packages
that referenced
this pull request
Jan 26, 2026
flutter/flutter@3134be8...d81cd3e 2026-01-12 47866232+chunhtai@users.noreply.github.com Migrate doc and code to use sendAnnounce (flutter/flutter#180776) 2026-01-12 engine-flutter-autoroll@skia.org Roll Packages from 51fe1d9 to e57e7f4 (3 revisions) (flutter/flutter#180846) 2026-01-12 dixita0607@users.noreply.github.com Fix: Allow dartpad embed clipboard-write permission for "Copy to clipboard" functionality (flutter/flutter#178057) 2026-01-12 engine-flutter-autoroll@skia.org Roll Dart SDK from 87fbfd5381b6 to 42fd9ef68c1a (1 revision) (flutter/flutter#180836) 2026-01-12 engine-flutter-autoroll@skia.org Roll Skia from aefdde600f1e to 487a9943210b (3 revisions) (flutter/flutter#180835) 2026-01-12 goderbauer@google.com Bump ffigen (flutter/flutter#180507) 2026-01-12 engine-flutter-autoroll@skia.org Roll Skia from d42a43daa6cf to aefdde600f1e (1 revision) (flutter/flutter#180829) 2026-01-12 ahmedsameha1@gmail.com Make sure that a LongPressDraggable doesn't crash in 0x0 environment (flutter/flutter#180408) 2026-01-12 ahmedsameha1@gmail.com Make sure that a FlutterLogo doesn't crash in 0x0 environment (flutter/flutter#180617) 2026-01-12 engine-flutter-autoroll@skia.org Roll Fuchsia Linux SDK from T_HOCpDjLgzi1SUMq... to VYeyMPe1lyCtlcl-V... (flutter/flutter#180825) 2026-01-11 engine-flutter-autoroll@skia.org Roll Skia from f39cc645b1dd to d42a43daa6cf (2 revisions) (flutter/flutter#180819) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages Please CC stuartmorgan@google.com,tarrinneal@google.com on the revert to ensure that a human is aware of the problem. To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is my attempt to handle #6537 for the FlutterLogo widget.