scinfu / SwiftSoup

SwiftSoup: Pure Swift HTML Parser, with best of DOM, CSS, and jquery (Supports Linux, iOS, Mac, tvOS, watchOS)
https://scinfu.github.io/SwiftSoup/
MIT License
4.52k stars 345 forks source link

Thread 1: Fatal error: Index out of range #189

Closed SiuyuenChow closed 1 year ago

SiuyuenChow commented 3 years ago

Occasionally crashes occur when you are constantly pulling HTML data and parsing it with SwiftSoup Thread 1: Fatal error: Index out of range

Element.swift

Crash code location: /

public var startIndex: Int { return this.startIndex }

public var endIndex: Int { return this.endIndex }

/// The number of Element objects in the collection. /// Equivalent to size() public var count: Int { return this.count } }

scinfu commented 2 years ago

can you share an HTML?