Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error_code=214 after first app load with asyncOpen #6178

Closed
ritter1 opened this issue Jun 13, 2019 · 2 comments · Fixed by realm/realm-object-store#802
Closed

error_code=214 after first app load with asyncOpen #6178

ritter1 opened this issue Jun 13, 2019 · 2 comments · Fixed by realm/realm-object-store#802
Assignees

Comments

@ritter1
Copy link

ritter1 commented Jun 13, 2019

Goals

asyncOpen a realm in a freshly installed iOS app with RealmSwift 3.16.1

Expected Results

Connect to and sync with realm in the app.

Actual Results

ToDo[4923:23491947] Sync: Connection[1]: Session[1]: client_reset_config = true, Realm exists = false, async open = true, client reset = false
ToDo[4923:23491947] Sync: Connection[1]: Session[1]: Client reset config, metadata_dir = '/Users/xyz/Library/Developer/CoreSimulator/Devices/78F11C8E-D00C-46C5-98A0-B8EB0E104665/data/Containers/Data/Application/C58326A9-CE07-4305-8480-15EC5C24FC43/Documents/realm-object-server/io.realm.object-server-state/', recover_local_changes = true, require_recent_state_realm = true
ToDo[4923:23491947] Sync: Connection[1]: Connected to endpoint '3.122.70.141:443' (from '192.168.1.52:61900')
ToDo[4923:23491947] Sync: Connection[1]: Session[1]: Received: ERROR(error_code=214, message_size=21, try_again=0)
ToDo[4923:23491947] Sync: Connection[1]: Disconnected

Steps to Reproduce

  1. Setup https://github.com/realm/my-first-realm-app/tree/master/ios/01-query-based-sync with RealmSwift 3.13.1 and run in the simulator with iOS 12.2
  2. After the first app start, create a nickname account within the app.
  3. Delete the app from the simulator.
  4. In WelcomeViewController.swift, line 66, comment out initializeRealmPermissions(realm) as this is supposed to run only once.
  5. Install and run the app again on the simulator. > Runs fine!
  6. Delete app again.
  7. Upgrade RealmSwift to 3.16.1.
  8. Install and run the app again on the simulator. > Received: ERROR(error_code=214, message_size=21, try_again=0)

Code Sample

Code is used as in https://github.com/realm/my-first-realm-app/tree/master/ios/01-query-based-sync

Version of Realm and Tooling

Realm framework version: 3.16.1

Realm Object Server version: 3.23.1

Xcode version: 10.2.1 (10E1001)

iOS version: 12.2

@tgoyne
Copy link
Member

tgoyne commented Jun 13, 2019

asyncOpen doesn't do anything particularly interesting or useful on a query-based sync Realm, but it indeed shouldn't be outright failing like this.

@ritter1
Copy link
Author

ritter1 commented Jun 17, 2019

Thanks, received the fix in 3.16.2 just a couple of days after I reported the problem. Cool!

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 15, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants