Skip to content

Commit

Permalink
describegpt: rename const from OPEN_AI_KEY_ERROR to LLM_APIKEY_ERROR
Browse files Browse the repository at this point in the history
Rate limit · GitHub

Whoa there!

You have triggered an abuse detection mechanism.

Please wait a few minutes before you try again;
in some cases this may take up to an hour.

jqnatividad committed Apr 21, 2024
1 parent 592ff87 commit da6a028
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/cmd/describegpt.rs
Original file line number Diff line number Diff line change
@@ -92,7 +92,7 @@ struct PromptFile {
jsonl: bool,
}

const OPENAI_KEY_ERROR: &str = "Error: QSV_LLM_APIKEY environment variable not found.\nNote that \
const LLM_APIKEY_ERROR: &str = "Error: QSV_LLM_APIKEY environment variable not found.\nNote that \
this command uses LLMs for inferencing and is therefore prone to \
inaccurate information being produced. Verify output results \
before using them.";
@@ -577,11 +577,11 @@ pub fn run(argv: &[&str]) -> CliResult<()> {
// Check if the --api-key flag is present
if let Some(api_key) = args.flag_api_key.clone() {
if api_key.is_empty() {
return fail!(OPENAI_KEY_ERROR);
return fail!(LLM_APIKEY_ERROR);
}
api_key
} else {
return fail!(OPENAI_KEY_ERROR);
return fail!(LLM_APIKEY_ERROR);
}
},
};

0 comments on commit da6a028

Please sign in to comment.