-
-
Notifications
You must be signed in to change notification settings - Fork 739
Cursor/fix nginx UI issue 1455 gpt 5.1 codex high 079c #1461
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cursor/fix nginx UI issue 1455 gpt 5.1 codex high 079c #1461
Conversation
Co-authored-by: jacky-943572677 <[email protected]>
Co-authored-by: jacky-943572677 <[email protected]>
|
@cursoragent resolve conflicts |
|
冲突已处理完毕:我刚同步了最新的 Learn more about Cursor Agents |
|
@cursoragent 仍提示 internal/cron/incremental_indexing.go 存在冲突需要处理 |
|
已重新同步 Learn more about Cursor Agents |
| log.Path, log.LastSize, fileSize) | ||
| if rawLastSize > 0 && fileSize < rawLastSize { | ||
| logger.Debugf("File %s needs full re-indexing (fallback path) due to size decrease: old_size=%d, new_size=%d", | ||
| log.Path, rawLastSize, fileSize) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: Rotation check bypasses size clamping causing false positives
The fallback path comment explains that lastSize is clamped to prevent false positives when aggregated log sizes are larger than individual file sizes. However, the rotation check at line 149 uses rawLastSize (the unclamped value) instead of the clamped lastSize. When grouped log entries have an aggregated LastSize larger than the current file size, the condition fileSize < rawLastSize will always be true, triggering unnecessary re-indexing even when no actual rotation occurred. This defeats the purpose of the clamping fix for the growth check.
Additional Locations (1)
| log.Path, log.LastSize, fileSize) | ||
| if rawLastSize > 0 && fileSize < rawLastSize { | ||
| logger.Debugf("File %s needs full re-indexing (fallback path) due to size decrease: old_size=%d, new_size=%d", | ||
| log.Path, rawLastSize, fileSize) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: Rotation check bypasses size clamping causing false positives
The fallback path comment explains that lastSize is clamped to prevent false positives when aggregated log sizes are larger than individual file sizes. However, the rotation check at line 149 uses rawLastSize (the unclamped value) instead of the clamped lastSize. When grouped log entries have an aggregated LastSize larger than the current file size, the condition fileSize < rawLastSize will always be true, triggering unnecessary re-indexing even when no actual rotation occurred. This defeats the purpose of the clamping fix for the growth check.
Note
Incremental log indexing now consults persisted per-file metadata (with fallback heuristics) and improves rotation handling; adds unit tests for unchanged and growth scenarios.
logIndexProviderto decide when to reindex (needsIncrementalIndexing), with a safer fallback that clamps aggregated sizes and handles first-index and size-decrease cases.LogFileManagerand passes it intoneedsIncrementalIndexing.SetIndexStatuswith queue position; maintains status transitions and saves index metadata post-run.internal/cron/incremental_indexing_test.gowith stublogIndexProvider.Written by Cursor Bugbot for commit 34b7913. This will update automatically on new commits. Configure here.