mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-20 12:24:59 +00:00
refactor: Remove debug dump calls from repomap.py
This commit is contained in:
parent
cfd0e67a6b
commit
c823bf4fbb
1 changed files with 0 additions and 8 deletions
|
@ -249,7 +249,6 @@ class RepoMap:
|
||||||
|
|
||||||
# miss!
|
# miss!
|
||||||
data = list(self.get_tags_raw(fname, rel_fname))
|
data = list(self.get_tags_raw(fname, rel_fname))
|
||||||
dump(data)
|
|
||||||
|
|
||||||
# Update the cache
|
# Update the cache
|
||||||
try:
|
try:
|
||||||
|
@ -288,7 +287,6 @@ class RepoMap:
|
||||||
captures = query.captures(tree.root_node)
|
captures = query.captures(tree.root_node)
|
||||||
|
|
||||||
saw = set()
|
saw = set()
|
||||||
dump(USING_TSL_PACK)
|
|
||||||
if USING_TSL_PACK:
|
if USING_TSL_PACK:
|
||||||
all_nodes = []
|
all_nodes = []
|
||||||
for tag, nodes in captures.items():
|
for tag, nodes in captures.items():
|
||||||
|
@ -297,7 +295,6 @@ class RepoMap:
|
||||||
all_nodes = list(captures)
|
all_nodes = list(captures)
|
||||||
|
|
||||||
for node, tag in all_nodes:
|
for node, tag in all_nodes:
|
||||||
dump(node, tag)
|
|
||||||
if tag.startswith("name.definition."):
|
if tag.startswith("name.definition."):
|
||||||
kind = "def"
|
kind = "def"
|
||||||
elif tag.startswith("name.reference."):
|
elif tag.startswith("name.reference."):
|
||||||
|
@ -314,7 +311,6 @@ class RepoMap:
|
||||||
kind=kind,
|
kind=kind,
|
||||||
line=node.start_point[0],
|
line=node.start_point[0],
|
||||||
)
|
)
|
||||||
dump(result)
|
|
||||||
|
|
||||||
yield result
|
yield result
|
||||||
|
|
||||||
|
@ -411,7 +407,6 @@ class RepoMap:
|
||||||
personalization[rel_fname] = personalize
|
personalization[rel_fname] = personalize
|
||||||
|
|
||||||
tags = list(self.get_tags(fname, rel_fname))
|
tags = list(self.get_tags(fname, rel_fname))
|
||||||
dump(tags)
|
|
||||||
if tags is None:
|
if tags is None:
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
@ -440,7 +435,6 @@ class RepoMap:
|
||||||
# Helps with tree-sitter 0.23.2 with ruby, where "def greet(name)"
|
# Helps with tree-sitter 0.23.2 with ruby, where "def greet(name)"
|
||||||
# isn't counted as a def AND a ref. tree-sitter 0.24.0 does.
|
# isn't counted as a def AND a ref. tree-sitter 0.24.0 does.
|
||||||
for ident in defines.keys():
|
for ident in defines.keys():
|
||||||
dump(ident)
|
|
||||||
if ident in references:
|
if ident in references:
|
||||||
continue
|
continue
|
||||||
for definer in defines[ident]:
|
for definer in defines[ident]:
|
||||||
|
@ -451,7 +445,6 @@ class RepoMap:
|
||||||
progress()
|
progress()
|
||||||
|
|
||||||
definers = defines[ident]
|
definers = defines[ident]
|
||||||
dump(ident, definers)
|
|
||||||
if ident in mentioned_idents:
|
if ident in mentioned_idents:
|
||||||
mul = 10
|
mul = 10
|
||||||
elif ident.startswith("_"):
|
elif ident.startswith("_"):
|
||||||
|
@ -470,7 +463,6 @@ class RepoMap:
|
||||||
|
|
||||||
G.add_edge(referencer, definer, weight=mul * num_refs, ident=ident)
|
G.add_edge(referencer, definer, weight=mul * num_refs, ident=ident)
|
||||||
|
|
||||||
dump(G.nodes)
|
|
||||||
if not references:
|
if not references:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue