yorkie-team / dashboard

Dashboard is an administrative tool that allows users to manage projects and documents with ease.
https://yorkie.dev/dashboard/
Apache License 2.0
20 stars 13 forks source link

Script error when accessing a document created by ProseMirror example on dashboard #130

Open hackerwins opened 1 year ago

hackerwins commented 1 year ago

Description:

Script error when accessing a document created by ProseMirror example on dashboard

After creating the document of the ProseMirror example of the JS SDK, there seems to be a script error occurring when accessing the document on the Dashboard.

In the example, the selection is saved as a byte array type in the document to propagate it to the peers.

Screenshot 2023-06-28 at 2 07 44 PM

However, this seems to be causing a script error when performing JSON.parse on the Dashboard.

Why:

DongjaJ commented 11 months ago

can I try this?

hackerwins commented 11 months ago

@DongjaJ Sure.

The error occurs when assigning a byte array(Uint8Array) to a document.

https://github.com/yorkie-team/yorkie-js-sdk/blob/c12ef2583ad0f85c4774eea30f8451a93262f0d3/test/integration/primitive_test.ts#L58-L68

DongjaJ commented 11 months ago

I found the following error in the process of re-creating this issue.

  1. create the document of the ProseMirror example of the JS SDK
  2. access the document on the Dashboard
  3. click another tab (ex. Project overview, api, setting...)

And I could not recreate Error on this issue

에러 재생산 중 발생한 이슈
hackerwins commented 8 months ago

We have stabilized yorkie.Tree until the v0.4.7 release. For now, the error described in this issue does not recur for now.

For https://github.com/yorkie-team/dashboard/issues/130#issuecomment-1656606798: I have confirmed that the issue described in the comment still occurs in development mode. This is only happening in the development environment, so I guess it is related to the development mode.