Initialization of SwiftyTesseract has failed
cheuhyakuroku opened this issue · comments
when run app crash an show this error. @arrrrny
Fatal error: Initialization of SwiftyTesseract has failed. Check that the tessdata folder has been added to the project as a folder reference and contains the correct .traineddata files for the specified engine mode and language(s).:
Still am facing this same issue. But only when I debug in iPhone using Development certificate. I find out that its happening because of below code.
// SwiftTesseractOcrPlugin.swift:
func initializeTessData() { ... let fileManager = FileManager.default do { try fileManager.createSymbolicLink(at: sourceURL, withDestinationURL: destURL) } catch { print(error) // Error: "You don’t have permission to save the file “tessdata” in the folder “MyTAHSS”." UserInfo={NSFilePath=/var/containers/Bundle/Application/2F6D4902-A567-4028-A65E-AEF8805BF104/MyTAHSS.app/tessdata, NSUnderlyingError=0x281fef3f0 {Error Domain=NSPOSIXErrorDomain Code=1 "Operation not
permitted"}}
}
}`
Still am facing this same issue. But only when I debug in iPhone using Development certificate. I find out that its happening because of below code.
// SwiftTesseractOcrPlugin.swift:
func initializeTessData() { ... let fileManager = FileManager.default do { try fileManager.createSymbolicLink(at: sourceURL, withDestinationURL: destURL) } catch { print(error) // Error: "You don’t have permission to save the file “tessdata” in the folder “MyTAHSS”." UserInfo={NSFilePath=/var/containers/Bundle/Application/2F6D4902-A567-4028-A65E-AEF8805BF104/MyTAHSS.app/tessdata, NSUnderlyingError=0x281fef3f0 {Error Domain=NSPOSIXErrorDomain Code=1 "Operation not
permitted"}}
}
}`
I get the same error. Did you solve this?
why is this issue closed?
why is this issue closed?
Look at the solution siva suggested here:
#31