Skip to content

Commit b37a3a9

Browse files
committed
prefer .env over env var
1 parent 1d6a66c commit b37a3a9

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

eval_protocol/cli_commands/upload.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -602,9 +602,9 @@ def upload_command(args: argparse.Namespace) -> int:
602602
secrets_from_file = _load_secrets_from_env_file(env_file_path)
603603
secrets_from_env_file = secrets_from_file.copy() # Track what came from .env file
604604

605-
# Also ensure FIREWORKS_API_KEY from environment is included
605+
# Also consider FIREWORKS_API_KEY from environment, but prefer .env value
606606
fw_api_key_value = get_fireworks_api_key()
607-
if fw_api_key_value:
607+
if fw_api_key_value and "FIREWORKS_API_KEY" not in secrets_from_file:
608608
secrets_from_file["FIREWORKS_API_KEY"] = fw_api_key_value
609609

610610
if not fw_account_id and fw_api_key_value:

0 commit comments

Comments
 (0)