fix(user_tools): honor AWS profile S3 endpoints - #2106
Open
WilliamK112 wants to merge 3 commits into
Open
WilliamK112 wants to merge 3 commits into
WilliamK112 wants to merge 3 commits into
Conversation
WilliamK112
marked this pull request as ready for review
August 22, 2026 19:01
|
Signed-off-by: WilliamK112 <164879897+WilliamK112@users.noreply.github.com>
WilliamK112
force-pushed
the
codex/support-aws-profile-s3-endpoint
branch
from
September 9, 2026 16:52
210a278 to
b9c37d4
Compare
Signed-off-by: Ching-Wei Kang <ckang53@wisc.edu>
…ofile-s3-endpoint Signed-off-by: Ching-Wei Kang <ckang53@wisc.edu>
Contributor
Author
|
I addressed the latest parser finding in Fresh validation after the merge passes: 21 endpoint/path tests, 28 combined endpoint and cluster tests, Pylint 10.00/10, Flake8, Could you please take another look when convenient? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Add a shared S3 endpoint resolver used by both the Python
S3Fshandler and local Hadoop job argument construction. Existing explicit and environment behavior is preserved, with AWS profile configuration consulted only when no endpoint environment variable is set.Endpoint precedence is:
endpoint_overrideargument forS3FsAWS_ENDPOINT_URL_S3AWS_ENDPOINT_URLAWS_CONFIG_FILEor~/.aws/configProfile selection follows
AWS_PROFILE, thenAWS_DEFAULT_PROFILE, thendefault, and resolves exactly one active profile. If an explicitly selected profile has no endpoint, the resolver returns no override instead of falling through to another profile whose credentials are not active.The selected profile supports profile-level
endpoint_url, service-section S3 endpoints, and nested S3 endpoint configuration. Missing, malformed, or undecodable config files are ignored. AWS config is read as UTF-8 with interpolation disabled so percent-encoded endpoint URLs remain intact.For local Java jobs, a resolved custom endpoint is also passed as the Hadoop S3A endpoint with path-style access enabled.
Fixes #2087.
Validation
Merged current
dev(2073060) into the PR branch, then ran fromuser_tools:PYTHONPATH=src .venv/bin/python -m pytest tests/spark_rapids_tools_ut/test_csppath.py -q— 21 passedPYTHONPATH=src .venv/bin/python -m pytest tests/spark_rapids_tools_ut/test_csppath.py tests/spark_rapids_tools_ut/test_cluster.py -q— 28 passedpy_compileon the parsergit diff --check upstream/dev...HEAD