WeKnora icon indicating copy to clipboard operation
WeKnora copied to clipboard

[Bug]: FAQ import retry skips a new entry when a later row was merged first

Open juemimgcd opened this issue 1 week ago • 0 comments

Affected component

Backend Service & API, FAQ knowledge bases

Reproduction and observed behavior

Start with one existing FAQ. Append 51 distinct new standard questions, followed by an update to the existing question as row 52. Let the first batch of 50 creates finish and the next create fail. I reproduced this by setting the isolated workspace's storage quota between the cost of 50 and 51 new entries, then restoring it before the queue retried.

The worker updated row 52 first and checkpointed 51/52 after creating the first 50 rows. On retry it removed one unindexed chunk and resumed at input offset 51, which points to the existing question. The task returned completed, processed=52, failed_count=0, success_count=1 and skipped_count=51. PostgreSQL showed 50 of the 51 new questions active. The missing question was soft-deleted.

The expected result after the quota recovers is 51 new entries and one updated entry. A progress count includes out-of-order work and cannot be used as an input offset. This differs from #4827, which describes an import remaining stuck.

Environment

WeKnora Standard v0.9.1 (commit 71c32af), Linux arm64 containers on macOS, PostgreSQL with ParadeDB, Redis/Asynq and a local embedding model. Requests went directly to the backend API.

juemimgcd avatar Nov 25 '26 10:11 juemimgcd