mirror of
https://github.com/Aider-AI/aider.git
synced 2025-06-01 10:14:59 +00:00
copy
This commit is contained in:
parent
e76bd89bc1
commit
9348a10aaf
2 changed files with 8 additions and 7 deletions
|
@ -521,7 +521,8 @@ def main(argv=None, input=None, output=None, force_git_root=None, return_coder=F
|
|||
if args.show_model_warnings:
|
||||
problem = models.sanity_check_models(io, main_model)
|
||||
if problem:
|
||||
io.tool_output("You can skip this sanity check with --no-show-model-warnings")
|
||||
io.tool_output("You can skip this check with --no-show-model-warnings")
|
||||
io.tool_output()
|
||||
try:
|
||||
if not io.confirm_ask("Proceed anyway?"):
|
||||
return 1
|
||||
|
|
|
@ -742,11 +742,11 @@ def sanity_check_model(io, model):
|
|||
|
||||
if model.missing_keys:
|
||||
show = True
|
||||
io.tool_warning(f"Model {model}: Environment variables status:")
|
||||
io.tool_warning(f"Warning: {model} expects these environment variables")
|
||||
for key in model.missing_keys:
|
||||
value = os.environ.get(key, "")
|
||||
status = "✓ Set" if value else "✗ Not set"
|
||||
io.tool_warning(f"- {key}: {status}")
|
||||
io.tool_output(f"- {key}: {status}")
|
||||
|
||||
if platform.system() == "Windows" or True:
|
||||
io.tool_output(
|
||||
|
@ -756,12 +756,12 @@ def sanity_check_model(io, model):
|
|||
|
||||
elif not model.keys_in_environment:
|
||||
show = True
|
||||
io.tool_output(f"Model {model}: Unknown which environment variables are required.")
|
||||
io.tool_warning(f"Warning for {model}: Unknown which environment variables are required.")
|
||||
|
||||
if not model.info:
|
||||
show = True
|
||||
io.tool_output(
|
||||
f"Model {model}: Unknown context window size and costs, using sane defaults."
|
||||
io.tool_warning(
|
||||
f"Warning for {model}: Unknown context window size and costs, using sane defaults."
|
||||
)
|
||||
|
||||
possible_matches = fuzzy_match_models(model.name)
|
||||
|
@ -771,7 +771,7 @@ def sanity_check_model(io, model):
|
|||
io.tool_output(f"- {match}")
|
||||
|
||||
if show:
|
||||
io.tool_output(f"For more info, see: {urls.model_warnings}\n")
|
||||
io.tool_output(f"For more info, see: {urls.model_warnings}")
|
||||
|
||||
return show
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue