Skip to content

Refcell Already Borrowed error on mobile #5122

@rhaskia

Description

@rhaskia

Problem
When scrolling through a virtualised list on mobile, if I scroll too fast, I get the following error: "RefCell already borrowed" at Some(Location { file: "E:\\.cargo\\registry\\src\\index.crates.io-1949cf8c6b5b557f\\dioxus-core-0.7.2\\src\\runtime.rs", line: 280, column: 26 })

Steps To Reproduce
Happens when a large number of images are loaded through a use_asset_handler. I can't replicate it on a simpler project but it is definitely caused by the use_asset_handler.

Expected behavior
No panics/crash to happen.

Environment:

  • Dioxus version: v0.7.2
  • Rust version: 1.90 nightly
  • OS info: Windows 10
  • App platform: Mobile/Android

Questionnaire

I'm interested in fixing this myself but don't know where to start.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions