Skip to content

Fix Groovy FunctionNodeTypes misconfiguration #6

@DeusData

Description

@DeusData

Problem

Groovy method extraction returns 0 results because FunctionNodeTypes is configured with the wrong tree-sitter node type name.

Root Cause

The Groovy language spec uses function_definition but the tree-sitter-groovy grammar uses a different node type for method declarations. This means the pipeline never matches any Groovy methods.

Fix

  1. Run the AST dump test on a Groovy file to see actual node types: go test ./internal/pipeline/ -run TestASTDump -v
  2. Update FunctionNodeTypes in internal/lang/groovy.go to match the actual tree-sitter node type
  3. Verify with the benchmark repo (Spock: https://github.com/spockframework/spock)

Impact

Unlocks method extraction for all Groovy code. Currently scores 29% — fixing this should jump to 50%+.

References

  • Benchmark report: BENCHMARK_REPORT.md (Groovy section)
  • Language spec: internal/lang/groovy.go

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinggood first issueGood for newcomers

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions