Collab-server keeps phantom state of renamed files

Đang mở
#174 1 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
52/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
typescript
Lĩnh vực
backend

Hướng nghiên cứu

Start in the collab-server code that handles File Explorer renames and manages Y.Doc instances, then reproduce the a.txt → b.txt → a.txt sequence described in the issue. Done means reopening a.txt retains Version 3 rather than overwriting it with Version 2, while Ctrl-Z no longer restores the lost content.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

To replicate:

  • Open an new file a.txt in a fresh project. Make edits to it and save them. (This is Version 1 of the document)
  • Edit the document and do not save those changes (this is Version 2 of the document)
  • Rename the file to b.txt using the File Explorer. Due to the fix in #160, the b.txt document will correctly contain Version 2 of the document
  • Make further edits to b.txt. This is Version 3 of the document. You can save these, or not.
  • Rename b.txt back to a.txt using the file explorer.

Expected: the a.txt buffer contains Version 3 of the document
Actual: the a.txt buffer contains Version 2 of the document. Pressing Ctrl-Z restores Version 3 of the document.

Reason: the collab server kept around a phantom Y.Doc for a.txt, and when a buffer for a.txt was opened, the collab server overwrote the document with its document.

Replaces #146 — this is the part of #146 that wasn't fixed by #160.

Ngôn ngữ chính
TypeScript
Star
12
Fork
1
Merge trung bình
1 ngày 8 giờ
Pull request đã merge (30 ngày)
66

Chuẩn bị môi trường

  • Có Dockerfile hoặc tệp Docker Compose
  • Không có mẫu pull request
  • Không có hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của leanprover/lean-workbench

Tất cả issue của leanprover/lean-workbench

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.