Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion framework/codemodder-base/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ dependencies {
api(libs.java.security.toolkit)
api(libs.commons.lang3)

api("io.codemodder:codetf-java:4.2.1")
api("io.codemodder:codetf-java:4.5.0")
api(libs.slf4j.api)
api(libs.javaparser.core)
api(libs.javaparser.symbolsolver.core)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -337,9 +337,17 @@ private FilesUpdateResult updateFiles(

// create a changeset for this file change + its downstream dependency changes
List<CodeTFChangesetEntry> changeset = new ArrayList<>();
Strategy codeChangeStrategy = codeTFAiMetadata != null ? Strategy.AI : Strategy.DETERMINISTIC;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this affect every codemod? If so I can remove our logic for this in analysis service 🥳

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can figure that out in a separate change if needed, but this should be broadly correct if AI metadata is being provided correctly.

changeset.add(
new CodeTFChangesetEntry(
getRelativePath(projectDir, filePath), diff, changes, codeTFAiMetadata));
getRelativePath(projectDir, filePath),
diff,
changes,
codeTFAiMetadata,
codeChangeStrategy,
false,
List.of(),
null));
changeset.addAll(dependencyChangesetEntries);

// update the cache
Expand Down
Loading