ChartsOrg / ChartsOrg/Charts

Crash - Swift/arm64-apple-ios.swiftinterface:15276: Fatal error: Range requires lowerBound <= upperBound

Open
#4,733 2 comments 0 reactions 1 assignee Claimed by @pmairoldi View on GitHub
Dominant language
Swift
Stars
28k
Forks
6k
PR merge metrics
No merged PRs in 30d

Description

I have 3125 dat records. graph crashed with error - Swift/arm64-apple-ios.swiftinterface:15276: Fatal error: Range requires lowerBound <= upperBound.

Chart Data

var data = [ChartDataEntry]()
for result in sorted {
leftText = result.displayUnit
bottomText = result.displayRecordName
let yValue = result.recordedValue.value.doubleValue
let entry = ChartDataEntry(x: result.fromDate?.timeIntervalSince1970 ?? 0.0, y: yValue)
entry.data = result
data(entry)
}
data.sort(by: { $0.x < $1.x })

Screenshot 2021-10-08 at 3 29 12 PM

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.