Uploaded image for project: 'Realm Core'
  1. Realm Core
  2. RCORE-1860

C-API: `usercode_error` missing from `realm_sync_error`

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None

      When a client reset handler fails because of an error in the callback, the SDK calls realm_register_user_code_callback_error to store it. However, the error that we in the callback provided to realm_sync_config_set_error_handler is realm_sync_error, which doesn't contain a pointer to the original error. So we get an error with a message A fatal error occurred during client reset: 'User-provided callback failed' and code 1028, but we don't have a way to get to the original error that caused the problem.

      Note to self: to repro this in dart, throw a user exception in the client reset handler.

            Assignee:
            nicola.cabiddu@mongodb.com Nicola Cabiddu
            Reporter:
            nikola.irinchev@mongodb.com Nikola Irinchev
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: