Skip to content

Commit b408d55

Browse files
committed
fixes
1 parent cf2466a commit b408d55

File tree

5 files changed

+5
-6
lines changed

5 files changed

+5
-6
lines changed

examples/visualize_codebases/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Codebase Relationship Visualizations
22

3-
This example demonstrates four different approaches to visualizing code relationships using Codegen. Each visualization script creates a graph to help developers understand different aspects of code structure and dependencies.
3+
This set of examples demonstrates four different approaches to visualizing code relationships using Codegen. Each visualization script creates a graph to help developers understand different aspects of code structure and dependencies.
44

55
## Visualization Types
66

examples/visualize_codebases/blast_radius.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ def run(codebase: Codebase):
112112

113113
if __name__ == "__main__":
114114
print("Initializing codebase...")
115-
codebase = Codebase.from_repo("codegen-oss/posthog", programming_language=ProgrammingLanguage.PYTHON)
115+
codebase = Codebase.from_repo("codegen-oss/posthog", commit="81941c24897889a2ff2f627c693fa734967e693c", programming_language=ProgrammingLanguage.PYTHON)
116116
print(f"Codebase with {len(codebase.files)} files and {len(codebase.functions)} functions.")
117117
print("Creating graph...")
118118

examples/visualize_codebases/call_trace.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ def run(codebase: Codebase):
114114

115115
if __name__ == "__main__":
116116
print("Initializing codebase...")
117-
codebase = Codebase.from_repo("codegen-oss/posthog", programming_language=ProgrammingLanguage.PYTHON)
117+
codebase = Codebase.from_repo("codegen-oss/posthog", commit="b174f2221ea4ae50e715eb6a7e70e9a2b0760800", programming_language=ProgrammingLanguage.PYTHON)
118118
print(f"Codebase with {len(codebase.files)} files and {len(codebase.functions)} functions.")
119119
print("Creating graph...")
120120

examples/visualize_codebases/dependency_trace.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ def run(codebase: Codebase):
7676

7777
if __name__ == "__main__":
7878
print("Initializing codebase...")
79-
codebase = Codebase.from_repo("codegen-oss/posthog", programming_language=ProgrammingLanguage.PYTHON)
79+
codebase = Codebase.from_repo("codegen-oss/posthog", commit="b174f2221ea4ae50e715eb6a7e70e9a2b0760800", programming_language=ProgrammingLanguage.PYTHON)
8080
print(f"Codebase with {len(codebase.files)} files and {len(codebase.functions)} functions.")
8181
print("Creating graph...")
8282

examples/visualize_codebases/method_relationships.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
from codegen.sdk.core.function import Function
77
from codegen.sdk.core.external_module import ExternalModule
88
from codegen.sdk.core.class_definition import Class
9-
from codegen.sdk.core.interfaces.callable import FunctionCallDefinition
109

1110
G = nx.DiGraph()
1211

@@ -101,7 +100,7 @@ def run(codebase: Codebase):
101100

102101
if __name__ == "__main__":
103102
print("Initializing codebase...")
104-
codebase = Codebase.from_repo("codegen-oss/modal-client", programming_language=ProgrammingLanguage.PYTHON)
103+
codebase = Codebase.from_repo("codegen-oss/modal-client", commit="00bf226a1526f9d775d2d70fc7711406aaf42958", programming_language=ProgrammingLanguage.PYTHON)
105104
print(f"Codebase with {len(codebase.files)} files and {len(codebase.functions)} functions.")
106105
print("Creating graph...")
107106

0 commit comments

Comments
 (0)