Closed eitanaviv closed 4 years ago
@eitanaviv Is this still an issue? Can you update your version of Realm? The version you are using is fairly out of date.
Going to close this out as it's been a couple of months and a number of releases have occurred. If this is still an issue, please open a new ticket.
Goals
I want an encrypted Realm file to be used in my iOS app.
Expected Results
Have a working Realm based app to be working. It is working, but i'm getting many crash reports.
Actual Results
Fatal error: 'try!' expression unexpectedly raised an error: Error Domain=io.realm Code=2 "Unable to open a realm at path '/var/mobile/Containers/Data/Application/6D5367BE-6E60-49C2-A8DB-367AE9B2D723/Documents/myRealm.realm': Realm file decryption failed Path:." UserInfo={Error Code=2, NSFilePath=/var/mobile/Containers/Data/Application/6D5367BE-6E60-49C2-A8DB-367AE9B2D723/Documents/myRealm.realm, Underlying=Realm file decryption failed Path: /var/mobile/Containers/Data/Application/6D5367BE-6E60-49C2-A8DB-367AE9B2D723/Documents/myRealm.realm, NSLocalizedDescription=Unable to open a realm at path '/var/mobile/Containers/Data/Application/6D5367BE-6E60-49C2-A8DB-367AE9B2D723/Documents/myRealm.realm': Realm file decryption failed Path:.}: file /Users/eitanimac/Desktop/ios_apps/EitanApp/EitanApp/AppDelegate.swift, line 93
Steps to Reproduce
I have no idea as i cannot manage to reproduce it myself and none of my co-workers with iOS seem to experience any bugs with the app.
Code Sample
Version of Realm and Tooling
As i said, the crash happen in many devices that i can see in Fabric, but none of my co-workers can seem to experience any crashes from the app.
The code sample i've put is combined from many solutions i found in the internet.
Looking forward to get some help and solve this already! Thanks!