Conversation
|
Hi @nank1ro . Thanks for the PR! It's been a long time since I wrote that code, and I'm almost certain there was an important reason it introduces the zero length delay. I believe I had this optimization in place early on, but had to remove it. I'm not certain, but it may have to do with ensuring callbacks and events fire in a predictable manner. Perhaps due to it causing race conditions when there are callbacks at Sorry for the vague response. I'll try to look into this in more detail soon — including writing a solid callback test if there isn't one already. Feel free to do some investigation on your end if you'd like though. |
|
Hi @gskinner, do you have any updates about it? |
|
Still digging into this. Up until 02aa06d I had an inline comment Unfortunately, I don't have any documentation on why, just a vague memory of testing it and finding issues with race conditions in some situations. I'm hoping to spend a bit more time with it today to see if I can remember the rationale (or determine it isn't an issue). |
Hi,
I'm opening a PR to fix a bug I have on shadcn_ui, related issue nank1ro/flutter-shadcn-ui#294
The problem is that
ShadAppusesShadToasterwhich usesAnimatefrom your package.When the user runs tests with it, it gets the following error
The test failing is the basic counter test:
Code for main app
Pubspec
The
ShadToasterdoesn't do nothing too special, just a basic usage with controller and effectsFor this reason, when the Duration is zero (which is the default) I don't schedule a timer.
I tried the fix locally, using the path directive and it works with the changes in the following PR