LineChart ChartsDemo-iOS crashes when we have a large amount of entries in a dataset
- Dominant language
- Swift
- Stars
- 28k
- Forks
- 6k
- PR merge metrics
- No merged PRs in 30d
Description
> ℹ To better understand the bug that is happening in the app I'm working on that uses Charts, I have modified your ChartsDemo-iOS application (Swift). When we have a large number of points on the LineChart, after a couple of zooms and rotations - the app crashes but only on iOS 12.
> It cannot be reproduced when the application is connected with an Xcode over cable or over a WiFi network. Logs say WatchDog killed the app.
> Logs:
Exception Type: EXC_CRASH (SIGKILL)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Termination Reason: Namespace SPRINGBOARD, Code 0x8badf00d
Termination Description: SPRINGBOARD, scene-update watchdog transgression: com.endress.eh-smartcare.dev exhausted real (wall clock) time allowance of 10.00 seconds | ProcessVisibility: Foreground | ProcessState: Running | WatchdogEvent: scene-update | WatchdogVisibility: Foreground | WatchdogCPUStatistics: ( | "Elapsed total CPU time (seconds): 257.150 (user 257.150, system 0.000), 62% CPU", | "Elapsed application CPU time (seconds): 149.137, 36% CPU" | )
Triggered by Thread: 0
## What did you do?
ℹ I set the count parameter in the setDataCount method to 15000, with the goal of having many more points on the Chart. The change is in the LineChart1ViewController.swift class:
# Line 108:
self.setDataCount(Int(15000), range: UInt32(sliderY.value))
## What did you expect to happen?
ℹ Smooth zoom and chart rotation.
## What happened instead?
ℹ On iOS 12, the app crashes after a few quick zooms and screen rotations.
## Charts Environment
**Charts version/Branch/Commit Number:** The latest one.
**Xcode version:** 12.4
**Swift version:** 5.0
**Platform(s) running Charts:** iOS 12
**macOS version running Xcode:** macOS Big Sur 11.2.3
## Demo Project
ℹ Your ChartsDemo-iOS application
Contributor guide
Assessment
This issue has not been assessed yet.