Skip to content

Commit f6ec81d

Browse files
committed
change error message
1 parent f74bef7 commit f6ec81d

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

codeflash/code_utils/env_utils.py

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,6 @@
1212
from codeflash.code_utils.shell_utils import read_api_key_from_shell_config
1313

1414

15-
class FormatterNotFoundError(Exception):
16-
"""Exception raised when a formatter is not found."""
17-
18-
def __init__(self, formatter_cmd: str) -> None:
19-
super().__init__(f"Formatter command not found: {formatter_cmd}")
20-
21-
2215
def check_formatter_installed(formatter_cmds: list[str]) -> bool:
2316
return_code = True
2417
if formatter_cmds[0] == "disabled":
@@ -32,7 +25,7 @@ def check_formatter_installed(formatter_cmds: list[str]) -> bool:
3225
format_code(formatter_cmds, tmp_file)
3326
except Exception:
3427
print(
35-
"⚠️ Failed to format code since formatter was not found in the environment. Please install it and try again."
28+
"⚠️ Codeflash requires a code formatter to be installed in your environment, but none was found. Please install a supported formatter, verify the formatter-cmds in your codeflash pyproject.toml config and try again."
3629
)
3730
sys.exit(1)
3831
return return_code

0 commit comments

Comments
 (0)