Skip to content

fix(output): fail-closed when AWS credentials missing - #32

Open
Bartok9 wants to merge 1 commit into
Auromix:ros2-humblefrom
Bartok9:aerial/aws-session-fail-closed
Open

fix(output): fail-closed when AWS credentials missing#32
Bartok9 wants to merge 1 commit into
Auromix:ros2-humblefrom
Bartok9:aerial/aws-session-fail-closed

Conversation

@Bartok9

@Bartok9 Bartok9 commented Jul 21, 2026

Copy link
Copy Markdown

Summary

Polly synthesis used to proceed even when AWS_ACCESS_KEY_ID / AWS_SECRET_ACCESS_KEY were missing or blank (boto3 then fails noisily, or worse, with partial env). This PR adds a pure aws_credentials_ok helper and fails closed in the feedback callback: log + publish output_error, skip synthesis.

Motivation

Embodied LLM stacks should not call paid cloud TTS without credentials. Matches the fail-closed style already used elsewhere in the series (OpenAI key, etc.).

Changes

  • llm_output/llm_output/aws_credentials.py — pure validator
  • llm_audio_output.py — early return when invalid
  • llm_output/test/test_aws_credentials.py — offline unit tests

Verification

cd llm_output && PYTHONPATH=. python3 test/test_aws_credentials.py -v
# 3 tests OK

AI-assisted; human-reviewed.

Skip Polly synthesis when AWS_ACCESS_KEY_ID/SECRET are missing or empty.
Pure helper + offline unit tests.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant