Permanently deleting a page containing an invalid advanced query from the recycle bin causes the graph to crash

オープン
#1,517 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

  • #14000 @tiensonqin による — マージされずにクローズ

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
25/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
領域
database

調査の方向性

Start by reproducing the crash with the incomplete advanced query ({} or { :query [] }) in a DB graph, then deleting that page from the Recycle bin. The payload names no files or tests, so locate the recycle-bin permanent-delete path and find where it loads or renders the page's blocks. Done means permanent deletion succeeds without the graph crashing, and a regression test covers deleting a page that holds an invalid advanced query.

索引モデルが issue の本文から書いたものです。

説明

Search first
  • I searched and no similar issues were found
What Happened?

I encountered this issue when trying to permanently delete a problematic page (loading the page causes the graph to crash) from the Recycle bin since I wanted to reuse the old name without logseq automatically repopulating the newly created page with the problematic contents.

The page in question contained an incomplete advanced query that causes the graph to crash whenever the page is opened (see my comment on the related issue )

Reproduce the Bug
  1. Create a DB graph (happens on an existing one too)
  2. create a new page and add an 'Advanced query" to a block inside it
  3. Inside the code block for the query type either of the following: {} or { :query [] } and click onto an empty block
  4. Observe the graph crashing with the "Something went wrong" page requiring a restart.
  5. Delete the page with the problematic query, sending it to the 'Recycle' as Logseq calls it.
  6. Delete the page from the Recycling bin.
  7. Observe the graph crashing with the "Something went wrong" page requiring a restart.
  8. Upon restart the page is deleted and the graph works perfectly.
Expected Behavior

A deleted page (that causes a graph to crash) is deleted and subsequently moved to the "Recycle" as Logseq calls it, should be deletable form the recycling bin without it being loaded in such a way as to cause a crash.

Screenshots
Image

Example of an advanced query code body that casues the crash the moment I click of of the query.

Desktop or Mobile Platform Information

EDIT: App version: 2.0.2
OS: Fedora Linux 44
Desktop Environment: KDE version 6.8.2

CPU: Intel® Core™ i7-10700K
GPU: AMD Radeon RX 6700 XT

Additional Context

No response

Are you willing to submit a PR? If you know how to fix the bug.
  • I'm willing to submit a PR (Thank you!)
主要言語
言語のデータがありません
スター
29
フォーク
2
PR マージ指標
30日以内にマージされた PR はありません

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

logseq/db-test のほかの issue

logseq/db-test の issue をすべて見る

似ている issue

Databases の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。