diff --git a/aider/io.py b/aider/io.py index f71340d92..ae2967719 100644 --- a/aider/io.py +++ b/aider/io.py @@ -694,11 +694,9 @@ class InputOutput: try: with self.chat_history_file.open("a", encoding=self.encoding, errors="ignore") as f: f.write(text) - except (PermissionError, OSError): - self.tool_error( - f"Warning: Unable to write to chat history file {self.chat_history_file}." - " Permission denied." - ) + except (PermissionError, OSError) as err: + print(f"Warning: Unable to write to chat history file {self.chat_history_file}.") + print(err) self.chat_history_file = None # Disable further attempts to write def format_files_for_input(self, rel_fnames, rel_read_only_fnames):