Uploaded image for project: 'Realm JavaScript SDK'
  1. Realm JavaScript SDK
  2. RJS-1144

Watch stream reports change after being cancelled

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

      We implemented a collection watch based on @kraenhansen's Codesandbox example. We found when closing the stream in a useEffect cleanup per the example, that we still received a change notification, despite having navigated away from the component that implemented the watch. Thinking our implementation was at fault, we spent quite some time trying to resolve the issue, only to find that it's reproducible in the aforementioned Codesandbox example. To reproduce, do the following in the Codesandbox example;

      1. press the Start watch stream button
      2. press the Stop watch stream button
      3. press the Start updates button

      You'll see one change event followed by a server error 200.

            Assignee:
            Unassigned Unassigned
            Reporter:
            unitosyncbot Unito Sync Bot
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: