Skip to content

Commit 00b4866

Browse files
Rangeet PanRangeet Pan
authored andcommitted
fixing tree-sitter bug
1 parent 983ac5d commit 00b4866

File tree

3 files changed

+39
-33
lines changed

3 files changed

+39
-33
lines changed

cldk/models/treesitter/models.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,9 @@ class Capture:
2828
name: str
2929

3030
def __init__(self, captures: List[Tuple[Node, str]]):
31-
self.captures = [self.Capture(node=node, name=text) for node, text in captures]
31+
self.captures = []
32+
for capture_name, captures in captures.items():
33+
self.captures = [self.Capture(node=node, name=capture_name) for node in captures]
3234

3335
def __getitem__(self, index: int) -> Capture:
3436
"""Get the capture at the specified index.

poetry.lock

Lines changed: 35 additions & 31 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ pandas = "^2.2.0"
1515
networkx = "^3.2.1"
1616
pyarrow = "^15.0.0"
1717
tree-sitter-languages = "^1.10.2"
18-
tree-sitter = "^0.22.3"
18+
tree-sitter = "0.23.0"
1919
rich = "^13.7.1"
2020
wget = "^3.2"
2121
requests = "^2.31.0"

0 commit comments

Comments
 (0)