mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-29 16:54:59 +00:00
do not sent file lists longer than 100 files
This commit is contained in:
parent
7d08c346bb
commit
ffe3da4df1
1 changed files with 4 additions and 2 deletions
|
@ -171,7 +171,7 @@ class Coder:
|
||||||
|
|
||||||
if self.repo is not None:
|
if self.repo is not None:
|
||||||
other_files = set(self.get_all_abs_files()) - set(self.abs_fnames)
|
other_files = set(self.get_all_abs_files()) - set(self.abs_fnames)
|
||||||
if other_files:
|
if other_files and len(other_files) < 100:
|
||||||
if self.use_ctags:
|
if self.use_ctags:
|
||||||
files_listing = get_tags_map(other_files)
|
files_listing = get_tags_map(other_files)
|
||||||
ctags_msg = " with selected ctags content"
|
ctags_msg = " with selected ctags content"
|
||||||
|
@ -498,7 +498,9 @@ class Coder:
|
||||||
silent=True,
|
silent=True,
|
||||||
)
|
)
|
||||||
except openai.error.InvalidRequestError:
|
except openai.error.InvalidRequestError:
|
||||||
self.io.tool_error("Failed to generate commit message using gpt-3.5-turbo due to an invalid request.")
|
self.io.tool_error(
|
||||||
|
"Failed to generate commit message using gpt-3.5-turbo due to an invalid request."
|
||||||
|
)
|
||||||
return
|
return
|
||||||
|
|
||||||
commit_message = commit_message.strip().strip('"').strip()
|
commit_message = commit_message.strip().strip('"').strip()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue