Skip to content

fix(scip): recompute total_files after supplementary pass to keep progress <= 100% - #1583

Merged
Shashankss1205 merged 1 commit into
CodeGraphContext:mainfrom
AloysJehwin:fix/scip-progress-exceeds-100
Aug 8, 2026
Merged

Shashankss1205 merged 1 commit into
CodeGraphContext:mainfrom
AloysJehwin:fix/scip-progress-exceeds-100

Conversation

@AloysJehwin

Copy link
Copy Markdown
Contributor

Fixes #1535

total_files was set to len(files_data) (the SCIP-covered count) before the supplementary Tree-sitter pass ran. The supplement then incremented processed past that total, giving progress percentages like 400%.

The fix recomputes total_files right after discover_files_to_index returns the supplementary list, so the denominator reflects the full set before counting starts. All 3 existing SCIP pipeline tests pass.

@vercel

vercel Bot commented Aug 5, 2026

Copy link
Copy Markdown

@AloysJehwin is attempting to deploy a commit to the shashankss1205's projects Team on Vercel.

A member of the Team first needs to authorize it.

@Shashankss1205 Shashankss1205 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.

Verified locally: trial-merged with the other four — full suite green (1153 passed, 7 skipped).

Correct fix for #1535. Recomputing total_files once the supplementary set is known is the right place — before the loop, so every processed_files update afterwards is measured against a total that can actually be reached.

Worth noting it composes correctly with #1566: that PR made parserless files emit a minimal File node and increment processed, and your count includes them (supplementary_files covers generic files too), so progress stays consistent rather than overshooting again by a different route. Thanks!

@Shashankss1205
Shashankss1205 merged commit 6954f87 into CodeGraphContext:main Aug 8, 2026
17 of 18 checks passed
@github-project-automation github-project-automation Bot moved this from Backlog tasks to Done in CGC Progress Board Aug 8, 2026
Shashankss1205 added a commit that referenced this pull request Aug 8, 2026
Ten PRs since 0.5.6 — mostly parser correctness, all with regression tests.

Parsers
- Ruby nested classes no longer delete their parent; method parameters
  extracted at all (#1523, #1527, #1581)
- C/C++ functions returning a pointer or reference are extracted, and
  registered in pre_scan so they resolve as call targets (#1524, #1582)
- C# fields and locals parsed, restoring receiver-type inference for
  `var x = new T(); x.M();` (#1525, #1584)
- JavaScript destructured, array and rest parameters extracted, recording
  the binding names rather than a placeholder (#1527, #1591)

Queries and analysis
- Five defects that returned wrong answers without erroring: inflated
  repository stats, misattributed callers, discarded graph_name,
  count(*) after OPTIONAL MATCH, an ignored tool argument (#1577)
- Dead-code detection made correct and self-consistent, including the
  JS module-level false positive (#600, #1559, #1578)

Indexing
- add_package_to_graph on a flat module no longer indexes the whole
  virtualenv (#1528, #1586)
- SCIP job progress no longer exceeds 100% (#1535, #1583)

Docs and tests
- Database Options table columns realigned (#1590)
- MCP tool definition contract validation (#1580)

Co-authored-by: Claude Fable 5 <[email protected]>
@Shashankss1205 Shashankss1205 added gssoc:approved GSSoC validation: counts toward scoring level:beginner GSSoC difficulty: 20 pts contributor / 10 mentor mentor:Shashankss1205 GSSoC mentor attribution: credits reviewing mentor quality:clean GSSoC quality: x1.2 contributor / +5 mentor type:bug GSSoC type bonus: bug labels Aug 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

gssoc:approved GSSoC validation: counts toward scoring level:beginner GSSoC difficulty: 20 pts contributor / 10 mentor mentor:Shashankss1205 GSSoC mentor attribution: credits reviewing mentor quality:clean GSSoC quality: x1.2 contributor / +5 mentor type:bug GSSoC type bonus: bug

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

bug(indexer): SCIP job progress exceeds 100% (observed 400%) and reports negative time remaining when SCIP covers only part of the repo

2 participants