feature: PartnerAppAuthProvider class support missing in 3.x (similar to 2.x) (5475) by aviruthen · Pull Request #5718 · aws/sagemaker-python-sdk

Description

The PartnerAppAuthProvider feature already exists in the V3 sagemaker-core package at sagemaker-core/src/sagemaker/core/partner_app/, with both auth_provider.py and auth_utils.py and corresponding tests. However, there are several V3 convention violations and discoverability issues that need to be addressed: (1) RequestsAuth is not re-exported from __init__.py files, so it lacks discoverability; (2) The auth_provider.py imports boto3 directly, which violates V3 conventions (V3 should use sagemaker-core session/credentials management, not raw boto3); (3) The classes don't follow V3 pydantic patterns for configuration. The primary fix involves ensuring proper re-exports, improving V3 convention compliance (replacing raw boto3 usage with sagemaker-core session management), and adding RequestsAuth to the public API exports.

Related Issue

Related issue: 5475

Changes Made

  • sagemaker-core/src/sagemaker/core/partner_app/auth_provider.py
  • sagemaker-core/src/sagemaker/core/partner_app/auth_utils.py
  • sagemaker-core/src/sagemaker/core/partner_app/__init__.py
  • sagemaker-core/src/sagemaker/core/__init__.py

AI-Generated PR

This PR was automatically generated by the PySDK Issue Agent.

  • Confidence score: 85%
  • Classification: type: feature request
  • SDK version target: V3

Merge Checklist

  • Changes are backward compatible
  • Commit message follows prefix: description format
  • Unit tests added/updated
  • Integration tests added (if applicable)
  • Documentation updated (if applicable)