chore: fix eslint exhaustive-deps and unused-assignment warnings#82
Merged
Conversation
Dependency ReviewThe following issues were found:
License Issuespackage.json
OpenSSF ScorecardScorecard details
Scanned Files
|
Contributor
There was a problem hiding this comment.
1 issue found and verified against the latest diff
Confidence score: 5/5
- In
server/search/indexing-pipeline.ts, the newconsole.log(filesToDelete.length)runs beforefilesToDeleteis populated, so it will always report0and can mislead debugging/operational triage without affecting runtime behavior—move the log to after the deletion list is built (or log after the conditional block) before merging.
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="server/search/indexing-pipeline.ts">
<violation number="1" location="server/search/indexing-pipeline.ts:90">
P3: The `console.log(filesToDelete.length)` on the added line always logs `0` because `filesToDelete` is initialized to `[]` just above and only gets populated ~7 lines later inside the `if (previousSha && vectorStore.hasIndex(key))` block. This appears to be either debug logging placed before the relevant code path or leftover instrumentation. Consider either removing the `console.log` or moving it to after the variable is populated (e.g., inside or after the `if` block) if the intent was to track incremental cleanup behavior.</violation>
</file>
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
Contributor
There was a problem hiding this comment.
2 issues found across 2 files (changes from recent commits).
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
Contributor
There was a problem hiding this comment.
1 issue found across 2 files (changes from recent commits).
Tip: Review your code locally with the cubic CLI to iterate faster.
Re-trigger cubic
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes ESLint warnings including react-hooks/exhaustive-deps and no-useless-assignment.
Summary by cubic
Fix ESLint warnings by adding a missing hook dependency, removing useless assignments, silencing unused params, and improving error context; also removes stray debug logs and bumps minor deps. No user-facing changes.
resetViewtouseEffectdeps inuseArchitectureStateto satisfyreact-hooks/exhaustive-deps.inPackageswrite inparsePnpmWorkspace; scopefilesToDeletein indexing; use_textin tests; use a stable key inMarkdownish.causeingetRepoFileContent.Written for commit d35895c. Summary will update on new commits.