Skip to content

MapView causes memory crash (JetsamEvent) on iPhone 16 Pro, works in simulator and desktop #71

Description

@dragonzo

Description:
My Kivy app uses kivy-garden/mapview to display OpenStreetMap tiles in a popup. The app works fine on desktop and in the Xcode iOS simulator, but crashes on a real iPhone 16 Pro. The crash log is a JetsamEvent, indicating the app is killed for excessive memory usage.

Steps to Reproduce:

Open a popup with MapView (no markers, overlays, or directions; just basic map tiles).
Wait a few seconds.
App crashes and closes on real device.

What I’ve Tried:

Set cache_dir=None and cache_dir="" in MapView to disable disk caching.
Removed all markers, overlays, and directions code.
Works in simulator, but crashes on real device.

Crash Log:
JetsamEvent shows "freeze_skip_reason:" : "out-of-budget" for my app process (MyApp).

Relevant Code:

mapview = MapView(
    zoom=10,
    lat=center_lat,
    lon=center_lon,
    cache_dir=None,  # Also tried ""
    map_source=https_source
)

Expected Behavior:
MapView should display map tiles without crashing due to memory usage.

Actual Behavior:
App is killed by iOS for exceeding memory budget (JetsamEvent).

Additional Info:

No crash in simulator or desktop.
Only basic MapView, no overlays or markers.
Disabling cache does not help.

Request:
Is there a way to reduce MapView memory usage or fully disable disk/memory caching for iOS?
Any workaround or patch to prevent this crash?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions