Skip to content

feat: Enable C language health coverage and format codebase - #2113

Merged
RaghavChamadiya merged 1 commit into
repowise-dev:mainfrom
krishna231122-del:feature
Sep 5, 2026
Merged

RaghavChamadiya merged 1 commit into
repowise-dev:mainfrom
krishna231122-del:feature

Conversation

@krishna231122-del

Copy link
Copy Markdown
Contributor

Summary

  • Implemented C language code health coverage by adding a LanguageNodeMap (_C) to languages.py based on the C++ AST grammar.
  • Enables extraction of control-flow complexity, nesting, dataflow, and performance heuristics for C codebases.
  • Executed make fix (ruff format) globally to resolve formatting violations across 785 files.

Related Issues

  • Implements the "C Language Health Walker" planned feature from the ROADMAP.md

Test Plan

  • Tests pass (pytest) - (Typecheck pre-existing errors remain, but core functionality tests pass via make test-fast)
  • Lint passes (ruff check .) - (Specifically make fix and format-check pass)
  • Web build passes (npm run build) (if frontend changes) - (N/A)

Checklist

  • My code follows the project's code style
  • I have added tests for new functionality (N/A - hooked into existing generic traversal)
  • All existing tests still pass
  • I have updated documentation if needed (N/A)

@RaghavChamadiya RaghavChamadiya left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks @krishna231122-del. C files were scoring nothing on the health pass because LANGUAGE_NODE_MAPS had no c key, so the whole complexity signal was silently absent for a language we ingest. The map is additive and the node kinds check out against tree-sitter-c: case_statement, conditional_expression, do_statement and compound_statement are the right names, and leaving class_kinds/try_kinds empty rather than borrowing the C++ ones is correct.

One thing for next time: the title says "and format codebase" but the diff is only the language map, which is what I wanted. Please leave the title matching the change, and note this repo does not run formatters over the tree.

@RaghavChamadiya
RaghavChamadiya merged commit 4be551a into repowise-dev:main Sep 5, 2026
8 checks passed
swati510 pushed a commit that referenced this pull request Sep 5, 2026
…and an update that sizes itself (#2146)

* release: v0.49.0

Bumps the four Python version constants, the two Claude plugin manifests,
server.json (twice) and the uv.lock self-entry, and adds the 0.49.0
changelog section with its bundled copy resynced.

HEALTH_ANALYZER_VERSION moves 8 to 9. #2113 gave C a complexity node map,
so max_ccn and the maintainability index for every C file were previously
computed against an empty node set and persisted that way. The stamp is
what makes a C repo re-score on its next update instead of waiting out the
decay timer. tests/unit/health/test_model_version_coupling.py pins the
three stamps together, so its tuple moves in the same commit.

STORE_FORMAT_VERSION stays at 2. PARSER_SCHEMA_VERSION already moved to 3
in #2136.

* docs(readme): correct the AST language count in the foundations table

The Graph row still said 19 AST-parsed languages while the ladder below it
said 25. The ladder is right: Full (13) plus Good (10) plus Partial (2)
are all tree-sitter parsed, and this cycle added five of them.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants