Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exception in your example app: The provided ScrollController is currently attached to more than one ScrollPosition. #10

Open
JanZeman opened this issue Feb 1, 2024 · 0 comments

Comments

@JanZeman
Copy link
Contributor

JanZeman commented Feb 1, 2024

Repro steps:

  1. Run your sample app via flutter run -d windows
  2. Scroll down to let's say line 500 on the first yellow tab
  3. Scroll up and QUICKLY switch to the second red tab
  4. Keep trying there and back - usually I get it reproduce within 30 seconds.

`══╡ EXCEPTION CAUGHT BY ANIMATION LIBRARY ╞═════════════════════════════════════════════════════════
The following assertion was thrown while notifying status listeners for AnimationController:
The provided ScrollController is currently attached to more than one ScrollPosition.
The Scrollbar requires a single ScrollPosition in order to be painted.
When the scrollbar is interactive, the associated ScrollController must only have one ScrollPosition
attached.The provided ScrollController must be unique to one ScrollView widget.

When the exception was thrown, this was the stack:
0 RawScrollbarState._debugCheckHasValidScrollPosition. (package:flutter/src/widgets/scrollbar.dart:1492:9)
1 RawScrollbarState._debugCheckHasValidScrollPosition (package:flutter/src/widgets/scrollbar.dart:1517:6)
2 RawScrollbarState._validateInteractions (package:flutter/src/widgets/scrollbar.dart:1428:14)
3 AnimationLocalStatusListenersMixin.notifyStatusListeners (package:flutter/src/animation/listener_helpers.dart:240:19)
4 AnimationController._checkStatusChanged (package:flutter/src/animation/animation_controller.dart:815:7)
5 AnimationController._startSimulation (package:flutter/src/animation/animation_controller.dart:749:5)
6 AnimationController._animateToInternal (package:flutter/src/animation/animation_controller.dart:612:12)
7 AnimationController.reverse (package:flutter/src/animation/animation_controller.dart:495:12)
8 RawScrollbarState._maybeStartFadeoutTimer. (package:flutter/src/widgets/scrollbar.dart:1625:37)
12 _RawReceivePort._handleMessage (dart:isolate-patch/isolate_patch.dart:184:12)
(elided 3 frames from class _Timer and dart:async-patch)

The AnimationController notifying status listeners was:
AnimationController#f54e4(◀ 1.000)
════════════════════════════════════════════════════════════════════════════════════════════════════`

codenameakshay added a commit that referenced this issue Aug 23, 2024
…currently attached to more than one ScrollPosition. #10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant