Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Deleting a file from the editor's own "⋯" menu fails with 423 Locked: Text's own lock blocks it

未关闭
#9,310 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
56/100
Issue 类型
缺陷
描述清晰度
基本清楚
活跃度
活跃
技术栈
javascript
领域
frontend

调研方向

Trace the editor's ⋯ → Delete action and the Text session/lock lifecycle first; reproduce with the Temporary files lock (files_lock) app enabled and inspect the DELETE request. Done when deleting from the open editor succeeds without a 423 response and the session lock is released or its token is used.

由索引模型根据 Issue 内容生成。

描述

bug

With a Markdown file open in Text (in the Viewer), choosing Delete from the editor's "⋯" action menu fails with AxiosError: Request failed with status code 423. The file is not deleted. Closing and reopening the file and trying again gives the same error. The Delete option in the editor is therefore unusable.

The lock that blocks it is Text's own editing lock (Temporary files lock app, owner Text). Text holds that lock while its session is open, and the Viewer's Delete sends a plain WebDAV DELETE without the lock token and without ending Text's session first, so the server refuses it. Closing the editor first and deleting from the Files list works.

Steps to reproduce
Make sure the Temporary files lock (files_lock) app is enabled.
In Files, create a new Markdown file, type a few lines and let it save.
In the open editor, choose ⋯ → Delete.
Error toast: AxiosError: Request failed with status code 423; the file stays.
Close the editor, reopen the file, repeat step 3: same error.
Close the editor and delete the file from the Files list: it works.
Expected behavior
Delete from inside the editor deletes the file: Text releases its lock (ends the session) before the delete is sent, or the delete is sent with the session's lock token.

Server log (one attempt; there were three, all identical)
webdav DELETE /remote.php/dav/files//.md Sabre\DAV\Exception\Locked
DELETE /remote.php/dav/files//.md Sabre\DAV\Exception\Locked (Uncaught exception)
Immediately before, the session was saving normally (POST /apps/text/session//save). After the editor was closed the lock was gone (occ files:lock --status : not locked).

Versions
Nextcloud Server 34.0.4 (Docker nextcloud:34-apache)
Text 8.0.0
Viewer 7.0.0-dev.0 (bundled)
Temporary files lock (files_lock) 34.0.1
Browser: Chrome Version 154.0.8037.93 (Official Build) (64-bit)

主要语言
JavaScript
星标
665
派生
133
平均合并
1 天 17 小时
30 天内合并 PR
172

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

nextcloud/text 的其他 Issue

查看 nextcloud/text 的全部 Issue

相似的 Issue

更多 JavaScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。