Skip to content

fix: prevent SageMaker TGI from being marked configured when only Bedrock keys are set#7284

Open
ibaaaaal wants to merge 1 commit intoblock:mainfrom
ibaaaaal:fix/sagemaker-tgi-config-collision
Open

fix: prevent SageMaker TGI from being marked configured when only Bedrock keys are set#7284
ibaaaaal wants to merge 1 commit intoblock:mainfrom
ibaaaaal:fix/sagemaker-tgi-config-collision

Conversation

@ibaaaaal
Copy link

@ibaaaaal ibaaaaal commented Feb 17, 2026

Summary

Fixes #7268 — Configuring Amazon Bedrock causes Amazon SageMaker TGI to appear as configured.

This PR also fixes a related issue: Amazon Bedrock itself was not appearing in the provider selection dropdown because all its config keys were optional.

Root Cause

Issue 1: SageMaker TGI incorrectly marked as configured

SAGEMAKER_ENDPOINT_NAME was declared as required=false in the provider metadata, while AWS_REGION and AWS_PROFILE were required=true with defaults. When a user configures Bedrock, the shared AWS_REGION/AWS_PROFILE keys get stored globally. The check_provider_configured() logic then sees SageMaker TGI's required keys are satisfied and marks it as configured, even though no SageMaker endpoint was actually set up.

Issue 2: Bedrock not appearing in provider dropdown

Amazon Bedrock had all config keys marked as required=false. The check_provider_configured() function returns false for providers with zero required keys, causing Bedrock to never appear as "configured" in the provider selection dropdown.

Fix

SageMaker TGI fix (sagemaker_tgi.rs):

  • Mark SAGEMAKER_ENDPOINT_NAME as required=true — it is already required at runtime
  • Mark AWS_REGION and AWS_PROFILE as required=false — consistent with Bedrock

Bedrock fix (bedrock.rs):

  • Mark AWS_REGION as required=true with default "us-east-1" — this ensures Bedrock is properly marked as configured when the region is set
  • Update test assertion to reflect correct expected behavior

Validation

  • cargo fmt --check — pass
  • cargo clippy -D warnings — pass
  • cargo test --release -p goose — 687 tests pass (4 unrelated failures in prompt_manager are pre-existing)

@ibaaaaal ibaaaaal force-pushed the fix/sagemaker-tgi-config-collision branch 3 times, most recently from c374dbb to 218824d Compare February 18, 2026 00:10
- SageMaker TGI: mark SAGEMAKER_ENDPOINT_NAME as required, AWS_REGION/AWS_PROFILE as optional
- Bedrock: mark AWS_REGION as required with default to fix is_configured always returning false

Signed-off-by: ibaaaaal rifaldi.51922721@mahasiswa.unikom.ac.id
@ibaaaaal ibaaaaal force-pushed the fix/sagemaker-tgi-config-collision branch from 218824d to 8a13da5 Compare February 18, 2026 00:14
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.

Bedrock Provider sets value on AWS Sage Manager

1 participant

Comments