From 7a72c80605c954c357b622941a7f3531f389bd06 Mon Sep 17 00:00:00 2001 From: Paul Gauthier Date: Fri, 30 Aug 2024 06:50:41 -0700 Subject: [PATCH] fixes #1232 --- aider/coders/wholefile_coder.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/aider/coders/wholefile_coder.py b/aider/coders/wholefile_coder.py index bfda70117..a3766559f 100644 --- a/aider/coders/wholefile_coder.py +++ b/aider/coders/wholefile_coder.py @@ -59,6 +59,10 @@ class WholeFileCoder(Coder): fname = fname.rstrip(":") fname = fname.strip("`") + # Issue #1232 + if len(fname) > 250: + fname = "" + # Did gpt prepend a bogus dir? It especially likes to # include the path/to prefix from the one-shot example in # the prompt.