Skip to content

fix(web): show queued memory extraction tasks as pending instead of failed - #18297

Merged
wangq8 merged 1 commit into
infiniflow:mainfrom
euvre:fix/memory-message-pending-status
Aug 14, 2026
Merged

wangq8 merged 1 commit into
infiniflow:mainfrom
euvre:fix/memory-message-pending-status

Conversation

@euvre

@euvre euvre commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

Problem

In the Memory → Messages page, memory extraction tasks that are stuck in the queue show a Failed status in the Action column, and clicking the status dot opens an empty process-log popup.

Root cause

Queued extraction tasks are created with progress = 0 and no progress_msg. getTaskStatus in web/src/pages/memory/memory-message/message-table.tsx mapped any progress <= 0 to RunningStatus.FAIL, so queued tasks were rendered as Failed. Since there is no progress message yet, the log popup has nothing to show.

Genuine failures are written by the extractor with progress = -1 together with an error message (internal/service/memory_extractor.go), so they always have details in the popup.

Fix

  • progress < 0 → RunningStatus.FAIL (real failures, with error message)
  • progress == 0 → RunningStatus.UNSTART (queued, renders a neutral dot and a Pending label from the existing RunningStatusMap)

Verification

Verified locally against a memory with queued extraction tasks: the Action column now shows a neutral status dot, and clicking it shows Status: Pending instead of Failed.

Type of change

  • Bug Fix (non-breaking change which fixes an issue)

…ailed

Memory extraction tasks that are created but not yet picked up have
progress = 0 and no progress_msg. getTaskStatus mapped any progress <= 0
to RunningStatus.FAIL, so these queued tasks were rendered as Failed and
their process-log popup was empty.

Map progress < 0 (set by the extractor on real failures, together with an
error message) to FAIL and progress == 0 to UNSTART, rendering a neutral
dot and a Pending status label.
@dosubot dosubot Bot added size:XS This PR changes 0-9 lines, ignoring generated files. 🐞 bug Something isn't working, pull request that fix bug. 🧰 typescript Pull requests that update Typescript code labels Aug 14, 2026
@euvre euvre added the ci Continue Integration label Aug 14, 2026
@euvre
euvre requested a review from wangq8 August 14, 2026 10:59
@coderabbitai

coderabbitai Bot commented Aug 14, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 80f0df9e-b430-47d8-824a-1a3f1f3b5734

📥 Commits

Reviewing files that changed from the base of the PR and between 2678a0c and c89c607.

📒 Files selected for processing (1)
  • web/src/pages/memory/memory-message/message-table.tsx

📝 Walkthrough

Walkthrough

The memory message table now maps negative progress to FAIL and zero progress to UNSTART. The task-progress indicator displays UNSTART with the secondary text color.

Changes

Task status display

Layer / File(s) Summary
Status mapping and indicator styling
web/src/pages/memory/memory-message/message-table.tsx
getTaskStatus distinguishes negative and zero progress. The UNSTART indicator uses the secondary text color.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Merge Risk: ⚪ Minimal · up to c89c6

The change makes queued memory extraction tasks display as Pending instead of Failed without altering genuine failure handling, and no actionable merge-blocking risk remains beyond normal checks and review.

Poem

I’m a rabbit with a task in sight,
Zero hops means “unstart” right.
Below the path, failure is clear,
Soft gray text keeps status near.
Hop, hop—clean states appear!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly describes the main fix: queued memory extraction tasks now appear as pending instead of failed.
Description check ✅ Passed The description explains the problem, root cause, fix, verification, and change type, although it uses Problem instead of the template's Summary heading.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@wangq8 wangq8 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. The root cause and mapping change are correct: queued tasks are created with progress = 0 and no progress_msg, so progress <= 0 \u2192 FAIL was wrong. Genuine failures are written with progress = -1 plus an error message, so splitting on progress < 0 \u2192 FAIL / progress == 0 \u2192 UNSTART is right. RunningStatus.UNSTART and RunningStatusMap[UNSTART] = 'Pending' already exist, so the log popup now correctly shows Pending instead of Failed.

One minor, non-blocking nit: the new dot color uses bg-text-secondary while the other three states use the semantic bg-state-* palette (bg-state-success/error/warning). If a neutral/pending token exists in that palette it'd be more consistent — cosmetic only.

@wangq8
wangq8 merged commit 0df1b24 into infiniflow:main Aug 14, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🐞 bug Something isn't working, pull request that fix bug. ci Continue Integration size:XS This PR changes 0-9 lines, ignoring generated files. 🧰 typescript Pull requests that update Typescript code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants