mirror of
https://github.com/AutoMaker-Org/automaker.git
synced 2026-02-01 20:23:36 +00:00
fix: correct model check for Codex API key validation
- Updated the model check logic to only consider "gpt-" prefixed models, removing the previous check for unsupported models. - Adjusted error message for authentication failures to provide clearer guidance on resolving API key issues.
This commit is contained in:
@@ -1092,7 +1092,7 @@ When done, summarize what you implemented and any notes for the developer.`;
|
||||
if (block.text && (block.text.includes("Invalid API key") ||
|
||||
block.text.includes("authentication_failed") ||
|
||||
block.text.includes("Fix external API key"))) {
|
||||
const isCodex = finalModel.startsWith("gpt-") || finalModel.startsWith("o");
|
||||
const isCodex = finalModel.startsWith("gpt-")
|
||||
const errorMsg = isCodex
|
||||
? "Authentication failed: Invalid or expired API key. " +
|
||||
"Please check your OPENAI_API_KEY or run 'codex login' to re-authenticate."
|
||||
|
||||
Reference in New Issue
Block a user