Repository navigation
Enabling or disabling a Chip/RawChip with a tooltip throws an exception #138287
Description
Activity
- changed the title
[-]Enabling or disabling a `Chip` with a tooltip throws an exception [/-][+]Enabling or disabling a `Chip`/`RawChip` with a tooltip throws an exception [/+]on Nov 11, 2023 - addedin triagePresently being triaged by the triage teamPresently being triaged by the triage team
on Nov 13, 2023 Reproducible using the code sample provided above.
flutter doctor -v
[!] Flutter (Channel stable, 3.13.9, on macOS 14.0 23A344 darwin-arm64, locale en-GB) • Flutter version 3.13.9 on channel stable at /Users/nexus/dev/sdks/flutter ! Warning: `flutter` on your path resolves to /Users/nexus/dev/sdks/flutters/bin/flutter, which is not inside your current Flutter SDK checkout at /Users/nexus/dev/sdks/flutter. Consider adding /Users/nexus/dev/sdks/flutter/bin to the front of your path. ! Warning: `dart` on your path resolves to /Users/nexus/dev/sdks/flutters/bin/dart, which is not inside your current Flutter SDK checkout at /Users/nexus/dev/sdks/flutter. Consider adding /Users/nexus/dev/sdks/flutter/bin to the front of your path. • Upstream repository https://github.com/flutter/flutter.git • Framework revision d211f42860 (3 weeks ago), 2023-10-25 13:42:25 -0700 • Engine revision 0545f8705d • Dart version 3.1.5 • DevTools version 2.25.0 • If those were intentional, you can disregard the above warnings; however it is recommended to use "git" directly to perform update checks and upgrades. [✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0-rc1) • Android SDK at /Users/nexus/Library/Android/sdk • Platform android-34, build-tools 34.0.0-rc1 • Java binary at: /Users/nexus/Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b829.9-10027231) • All Android licenses accepted. [✓] Xcode - develop for iOS and macOS (Xcode 15.0) • Xcode at /Applications/Xcode-15.0.0-Release.Candidate.app/Contents/Developer • Build 15A240d • CocoaPods version 1.13.0 [✓] Chrome - develop for the web • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome [✓] Android Studio (version 2022.3) • Android Studio at /Users/nexus/Applications/Android Studio.app/Contents • Flutter plugin can be installed from: 🔨 https://plugins.jetbrains.com/plugin/9212-flutter • Dart plugin can be installed from: 🔨 https://plugins.jetbrains.com/plugin/6351-dart • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b829.9-10027231) [✓] IntelliJ IDEA Ultimate Edition (version 2023.2.3) • IntelliJ at /Users/nexus/Applications/IntelliJ IDEA Ultimate.app • Flutter plugin version 76.0.4 • Dart plugin version 232.10072.19 [✓] VS Code (version 1.84.2) • VS Code at /Applications/Visual Studio Code.app/Contents • Flutter extension version 3.76.0 [✓] Connected device (3 available) • Nexus (mobile) • 00008020-001875E83A38002E • ios • iOS 17.1.1 21B91 • macOS (desktop) • macos • darwin-arm64 • macOS 14.0 23A344 darwin-arm64 • Chrome (web) • chrome • web-javascript • Google Chrome 119.0.6045.123 ! Error: Browsing on the local area network for Dean’s iPad. Ensure the device is unlocked and attached with a cable or associated with the same local area network as this Mac. The device must be opted into Developer Mode to connect wirelessly. (code -27) [✓] Network resources • All expected network resources are available. ! Doctor found issues in 1 category.[✓] Flutter (Channel master, 3.17.0-5.0.pre.64, on macOS 14.0 23A344 darwin-arm64, locale en-GB) • Flutter version 3.17.0-5.0.pre.64 on channel master at /Users/nexus/dev/sdks/flutters • Upstream repository https://github.com/flutter/flutter.git • Framework revision 2e088178e8 (7 hours ago), 2023-11-12 18:45:26 -0500 • Engine revision a18ee3c7f5 • Dart version 3.3.0 (build 3.3.0-120.0.dev) • DevTools version 2.30.0-dev.1 [✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0-rc1) • Android SDK at /Users/nexus/Library/Android/sdk • Platform android-34, build-tools 34.0.0-rc1 • Java binary at: /Users/nexus/Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b829.9-10027231) • All Android licenses accepted. [✓] Xcode - develop for iOS and macOS (Xcode 15.0) • Xcode at /Applications/Xcode-15.0.0-Release.Candidate.app/Contents/Developer • Build 15A240d • CocoaPods version 1.13.0 [✓] Chrome - develop for the web • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome [✓] Android Studio (version 2022.3) • Android Studio at /Users/nexus/Applications/Android Studio.app/Contents • Flutter plugin can be installed from: 🔨 https://plugins.jetbrains.com/plugin/9212-flutter • Dart plugin can be installed from: 🔨 https://plugins.jetbrains.com/plugin/6351-dart • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b829.9-10027231) [✓] IntelliJ IDEA Ultimate Edition (version 2023.2.3) • IntelliJ at /Users/nexus/Applications/IntelliJ IDEA Ultimate.app • Flutter plugin version 76.0.4 • Dart plugin version 232.10072.19 [✓] VS Code (version 1.84.2) • VS Code at /Applications/Visual Studio Code.app/Contents • Flutter extension version 3.76.0 [✓] Connected device (3 available) • Nexus (mobile) • 00008020-001875E83A38002E • ios • iOS 17.1.1 21B91 • macOS (desktop) • macos • darwin-arm64 • macOS 14.0 23A344 darwin-arm64 • Chrome (web) • chrome • web-javascript • Google Chrome 119.0.6045.123 ! Error: Browsing on the local area network for Dean’s iPad. Ensure the device is unlocked and attached with a cable or associated with the same local area network as this Mac. The device must be opted into Developer Mode to connect wirelessly. (code -27) [✓] Network resources • All expected network resources are available. • No issues found!Reacted by Amal Krishna- addedframeworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.p: material_uimaterial_ui package in flutter/packagesmaterial_ui package in flutter/packagesa: error messageError messages from the Flutter frameworkError messages from the Flutter frameworkhas reproducible stepsThe issue has been confirmed reproducible and is ready to work onThe issue has been confirmed reproducible and is ready to work onteam-designOwned by Design Languages teamOwned by Design Languages teamfound in release: 3.13Found to occur in 3.13Found to occur in 3.13found in release: 3.17Found to occur in 3.17Found to occur in 3.17and removedin triagePresently being triaged by the triage teamPresently being triaged by the triage team
on Nov 13, 2023 Is this error related to this error, since this error is also ponting at "AnimationController" ?
I haven't found any remedy for the "special case", and haven't had time to make a "proof-of-concept" either...- addedP2Important issues not at the top of the work listImportant issues not at the top of the work listtriaged-designTriaged by Design Languages teamTriaged by Design Languages team
on Nov 15, 2023 Is this error related to this error, since this error is also ponting at "AnimationController" ? I haven't found any remedy for the "special case", and haven't had time to make a "proof-of-concept" either...
I submitted a fix for this #138799. It might also fix the issue you reported. If not, feel free to file a new issue and tag me.
Reacted by Amal Krishna- moved this from PR submitted to Done (PR merged) in Nevercode
on Nov 21, 2023 - added a commit that references this issue
on Nov 21, 2023 - addedr: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer version
on Nov 21, 2023 This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of
flutter doctor -vand a minimal reproduction of the issue.- locked as resolved and limited conversation to collaborators
on Dec 5, 2023
Metadata
Metadata
Assignees
Labels
Type
Projects
- StatusShow more project fieldsDone (PR merged)
Is there an existing issue for this?
Steps to reproduce
RawChipor one of theChipwidgets that uses the underlyingRawChip'sisEnabledproperty, likeActionChip.onPressedto enable/disable the chip as setting theonPressedto null is equivalent to disabling the chip.(Full example in code section)
Expected results
When the state variable changes, the chip's enabled/disabled status should change without throwing an exception.
Actual results
When the chip's state is toggled via the supporting widget (here:
FloatingActionButton), the framework (RenderObject.markNeedsPaint) throws an exception. This is possibly happening because the render object (_RenderChip) is somehow prematurely disposed:This only happens when the chip has a tooltip. A little bit of debugging shows that the error is apparently thrown when the chip in the widget tree is replaced with a new chip from
_RenderChipState.didUpdateWidgetmethod when anAnimationController'sreverse()method is called (enableController.reverse()). Here is the stack as obtained by the_FrameCallbackEntry'sdebugStackproperty that throws the error:View debug stack
Code sample
Code sample
Screenshots or Video
Screenshots / Video demonstration
[Upload media here]
Logs
Logs
https://pastebin.com/ypH5DVBc
Flutter Doctor output
Doctor output