Realm Async open error "Operation canceled" Realm Error Domain=io.realm.unknown Code=89

Hi Team,

I’m using Realm framework for one of iOS application and facing below issue while opening Realm in async open mode. When we try to open ROS using Realm studio we are able to open realm files seamlessly without any issues.This issue is happening only when we are trying to open Realm instance using Async open from iOS side , we were getting below error.

Error Domain=io.realm.unknown Code=89 “Operation canceled” UserInfo={Category=realm.basic_system, NSLocalizedDescription=Operation canceled, Error Code=89}

we were using below Realm SDK API to open realm.

Realm.asyncOpen(configuration: config, callbackQueue: DispatchQueue.main) { realm, error in
                if error == nil {
// Return Realm Instance
                } else {
                    // capture error and show in console. Here we are getting above error.
                }
            }

I would like to understand what scenarios we will receive these " Operation Canceled " error from Realm Async open API. What could be the reason for getting these error. Is it issue with ROS connectivity?

Below is the Environment /SDK details.

Realm-cocoa : v4.3.2
ROS Server : 3.28.5
Xcode :11.3.1
iOS :13.3

Appreciate your inputs to identify root cause .

Thanks,
Seshu

@Udatha_VenkataSeshai Does the user have permission to open the realm? Also - asyncOpen is an asynchronous operation that goes over the network - are you able to call this on the main thread? Try removing that.

Is it possible that ROS server side compaction and/or vacuuming could cause this error?

1 Like

Its possible - do you have more logs on the client and server side?

We’ve opened an internal support ticket #00689754 with relevant client logs. @Udatha_VenkataSeshai can you also attach relevant server logs in the same timeframe as the client logs (i.e. with the same timestamps)?

Sure Ben - feel free to tag me on the ticket and support will reach out to me and I’ll have a look.

1 Like