Repository navigation
Description
Current behavior 🐛
ScrollPresenterTests.OffsetsChangeWithCustomDuration (runtime test, ScrollPresenterViewChangeTests.mux.cs) fails on the Linux Framebuffer CI leg on most master builds and on unrelated PRs. It passes on the other runtime-test legs, and a rerun doesn't clear it.
The test sets the ScrollAnimationStarting animation duration to 10 ms, calls ScrollTo(600, 400) and asserts:
Verify.IsLessThanOrEqual(viewChangedCount, 2u);On Framebuffer it sees 3, 4 or 5 ViewChanged events. The final offsets and ScrollPresenterViewChangeResult.Completed are correct, so only the event count is off.
It fails in the framebuffer run of roughly 20 of the last 25 CI builds I looked at (master and PRs that don't touch ScrollPresenter/InteractionTracker). #25140 already lists it as "pre-existing, fails on every master build" and doesn't address it.
Expected behavior 🎯
A 10 ms animation produces at most 2 ViewChanged events, as on the other heads and in the upstream MUX test. Either the test should not assume a frame rate, or the Framebuffer frame loop should be paced.
How to reproduce it (as minimally and precisely as possible) 🔬
- Build the
Uno.UI.RuntimeTestsSamplesApp for the Skia Linux Framebuffer head (software renderer, e.g. a CI-style virtual framebuffer without a real display). - Run only
ScrollPresenterTests.OffsetsChangeWithCustomDuration. - The test fails on
viewChangedCount <= 2(3 to 5 events seen).
I did not reproduce it locally on a Linux framebuffer. The failure is confirmed from CI history only. The analysis below is by code inspection, not runtime-proven.
Workaround 🛠️
None needed for apps. Test only: ignore the test on Framebuffer with [PlatformCondition], or assert on the final state instead of the event count.
Works on UWP/WinUI
N/A (Uno runtime test). The test is ported from the MUX ScrollPresenter tests, which assume ~60 fps pacing.
Affected platforms 📱💻🖥️
Skia - Linux Framebuffer (software renderer).
Uno.Sdk version (and other relevant versions) 📦
master at 0599dad (code read at this sha); failures observed on master CI builds from 2026-10-08 to 2026-10-10.
Anything else we need to know? 💬
Likely cause (hypothesis from code, not measured): the Framebuffer software render loop isn't paced to a real refresh rate.
SoftwareRendererrenders on a thread that waits for an invalidation, then callsRender(), then_fbDev.VSync().VSync()callsioctl(FBIO_WAITFORVSYNC)and ignores the result (SoftwareRenderer.cs, FrameBufferDevice.VSync). On a virtual or driverless framebuffer that ioctl probably fails immediately, so frames run back to back at render speed.- Other heads pace frames with a timer (
FramePacer, ~16 ms), which gives at most 1 to 2 frames inside a 10 ms animation. InteractionTrackerCustomAnimationStatemoves the tracker once per frame (OnFrameStarting), and each position change enqueuesValuesChanged, which raisesScrollPresenter.ViewChanged(InteractionTracker.SetPosition). Several frames inside 10 ms therefore give severalViewChangedevents, matching the 3 to 5 seen.
Related: #25140 stretches the other timing-sensitive ScrollPresenter tests to 1 to 5 s for slow-frame WebGPU lanes. This test is the fast-frame mirror image and would need the same kind of treatment, or a pacing fix in the Framebuffer renderer.
Suggested next step: log frame timestamps and ViewChanged sources during the 10 ms animation on a framebuffer run to confirm, then either pace SoftwareRenderer or make the test frame-rate independent.
Activity
fix(framebuffer): Pace software rendering when vsync is unavailable
test(framebuffer): Cover software rendering frame pacing