Collab-server keeps phantom state of renamed files

Abierto
#174 1 comentario 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
52/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
typescript
Área
backend

Línea de trabajo

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.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

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.

Lenguaje dominante
TypeScript
Estrellas
12
Forks
1
Merge medio
1 d 8 h
PR fusionados (30 d)
66

Preparar el entorno

  • Incluye un Dockerfile o un archivo de Docker Compose
  • Sin plantilla de pull request
  • Sin guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de leanprover/lean-workbench

Todos los issues de leanprover/lean-workbench

Issues similares

Más issues de TypeScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.