Giter VIP home page Giter VIP logo

Comments (9)

georeith avatar georeith commented on May 23, 2024 1

@tommoor thanks for the heads up, will give it a go.

Ive seen some interesting things coming to the provider like random reconnect intervals that I am keen on. 🤞

from hocuspocus.

georeith avatar georeith commented on May 23, 2024 1

@ValentaTomas @tommoor this is still an issue. I made a video of the difference between the two providers in my application. I know it isn't enough to debug the issue just wanted to show that there is a difference still at least:

still.persists.mp4

If I had to guess I think its to do with setting nested Y.Map/Y.Array as my data structure looks something like:

Y.Map {
   items: Y.Map {
       '123': Y.Map {
           itemProps: Y.Map {
               matrix: Y.Array []
           }
        }
   }
}

Replacing this matrix above with a new Y.Array is what is happening in the video and with the @hocuspocus/provider the matrix is deleted, with y-websocket the update happens correctly.

This only appears to happen when I load the documents out of indexeddb first (why I had to leave the document and re-enter for the video above).

from hocuspocus.

tommoor avatar tommoor commented on May 23, 2024 1

Thank you for the video, this is very helpful. We've been discussing some extra tooling to make debugging this type of situation a little easier, but to me this is one of the most critical bugs on the list right now – it might be indicative of deeper sync problems.

from hocuspocus.

tommoor avatar tommoor commented on May 23, 2024

You might want to give this another try, up until hocuspocus/[email protected] the server was initiating the sync protocol rather than the client – this could have had some odd effects.

from hocuspocus.

ValentaTomas avatar ValentaTomas commented on May 23, 2024

I just tried it yesterday and I think the problem is still there. Any success @georeith ?

from hocuspocus.

hanspagel avatar hanspagel commented on May 23, 2024

Thanks for the bug report!

Just for reference, I’ll follow-up here with more ideas to improve the debugging: #187

I’ve just compared the relevant code for handling document updates in y-websocket and the @hocuspocus/provider and couldn’t see any issue.

Will dig deeper. ⛏️

from hocuspocus.

hanspagel avatar hanspagel commented on May 23, 2024

I think we fixed it. Would you mind to test again with @hocuspocus/[email protected] @georeith?

from hocuspocus.

georeith avatar georeith commented on May 23, 2024

@hanspagel I haven't had a chance to test with the latest @hocuspocus/server but I've just tried @hocuspocus/[email protected] and it appears the issue is now fixed 😀

from hocuspocus.

tommoor avatar tommoor commented on May 23, 2024

Going to close this as resolved, please reopen if need be.

from hocuspocus.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.