stephencelis / SQLite.swift

A type-safe, Swift-language layer over SQLite3.
MIT License
9.57k stars 1.54k forks source link

Not running on real device (TestFlight) #1188

Open AlanFloyd opened 1 year ago

AlanFloyd commented 1 year ago

Swift version: 5 tvOS Deployment Targe 15.6 Integrated with Swift Package manager

I am facing the following issue: My app runs perfect and without any issue on Simulator, but when publishing with TestFlight the app crashes on Start, only flickering. In Xcode Organizar I see that the crash is with the statement

db = try Connection("(path)/db.sqlite3")

here the complete code:

import SQLite

var db: Connection!

`do { let path = NSSearchPathForDirectoriesInDomains( .documentDirectory, .userDomainMask, true ).first!

        db = try Connection("\(path)/db.sqlite3")

    } catch let parsingError {

        print ("ERROR", parsingError)
    }

`It seams that the database is not possible to create on real AppleTV. Any idea?

Many thanks for help Dietmar