Please use the latest Xcode(9.3) for latest Fuzi(2.0.2).
For Xcode 9.2 please use Fuzi 2.0.1
guard let documentsDirectory = FileManager.default.urls(for: .documentDirectory, in: .userDomainMask).first else {
fatalError("Could not access documents directory when setting up Realm")
}
let realmDirectoryPath = documentsDirectory.appendingPathComponent("Realm")
do {
// Disable file protection to allow Realm to be used during Background App Refresh.
// See https://realm.io/docs/swift/latest/#using-realm-with-background-app-refresh
try FileManager.default.createDirectory(atPath: realmDirectoryPath.path, withIntermediateDirectories: true, attributes: [.protectionKey: FileProtectionType.none])
} catch {
fatalError("Error creating directory: \(error.localizedDescription)")
}
let realmURL = realmDirectoryPath.appendingPathComponent("default.realm")