File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -45,7 +45,7 @@ class ProvideApiKeyParams:
45
45
@server .feature ("getOptimizableFunctionsInCurrentDiff" )
46
46
def get_functions_in_current_git_diff (
47
47
server : CodeflashLanguageServer , _params : OptimizableFunctionsParams
48
- ) -> dict [str , str | list [str ]]:
48
+ ) -> dict [str , str | dict [ str , list [str ] ]]:
49
49
functions = get_functions_within_git_diff (uncommitted_changes = True )
50
50
file_to_funcs_to_optimize , _ = filter_functions (
51
51
modified_functions = functions ,
@@ -55,8 +55,10 @@ def get_functions_in_current_git_diff(
55
55
module_root = server .optimizer .args .module_root ,
56
56
previous_checkpoint_functions = {},
57
57
)
58
- qualified_names : list [str ] = [func .qualified_name for funcs in file_to_funcs_to_optimize .values () for func in funcs ]
59
- return {"functions" : qualified_names , "status" : "success" }
58
+ file_to_qualified_names : dict [str , list [str ]] = {
59
+ str (path ): [f .qualified_name for f in funcs ] for path , funcs in file_to_funcs_to_optimize .items ()
60
+ }
61
+ return {"functions" : file_to_qualified_names , "status" : "success" }
60
62
61
63
62
64
@server .feature ("getOptimizableFunctions" )
You can’t perform that action at this time.
0 commit comments