Skip to content

Commit 67d3f19

Browse files
committed
fixed isort
1 parent fa93df6 commit 67d3f19

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

codeflash/benchmarking/instrument_codeflash_trace.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -98,12 +98,12 @@ def instrument_codeflash_trace_decorator(
9898
"""Instrument __init__ function with codeflash_trace decorator if it's in a class."""
9999
# Instrument fto class
100100
original_code = function_to_optimize.file_path.read_text(encoding="utf-8")
101-
102-
# Modify the code
103-
modified_code = isort.code(add_codeflash_decorator_to_code(
101+
new_code = add_codeflash_decorator_to_code(
104102
original_code,
105103
function_to_optimize
106-
))
104+
)
105+
# Modify the code
106+
modified_code = isort.code(code=new_code, float_to_top=True)
107107

108108
# Write the modified code back to the file
109109
function_to_optimize.file_path.write_text(modified_code, encoding="utf-8")

0 commit comments

Comments
 (0)