Skip to content

Index out of bound in case of tree sitter based unused import code #141

Closed

Description

@rangeetpan

Describe the bug
When using the unused import removal code using tree-sitter, getting index out of bound when import statements are very weirdly generated by LLM
import org;

To Reproduce

import org;

Activity

  1. self-assigned this
    on Sep 4, 2025
  2. rahlk commented on Aug 3, 2026

    @rahlk
    Collaborator

    Closing as stale as part of a backlog cleanup. The code path is still live (TreesitterSanitizer.remove_unused_imports, referenced at cldk/core.py:388), but the report has no reproducing input attached and is ~333 days old, so there's nothing concrete to fix against. If this still bites, please reopen with the source file or snippet that triggers the index error and it'll be triaged properly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions