forked from ClickHouse/ClickHouse
-
Notifications
You must be signed in to change notification settings - Fork 18
Fix wrong path encoding #1537
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
zvonand
merged 5 commits into
antalya-25.8
from
bugfix/antalya-25.8/1536_fix_wrong_path_decodig
Mar 20, 2026
Merged
Fix wrong path encoding #1537
Changes from 2 commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
38a7629
Fix wrong path encoding
ianton-ru b516685
Turn off encoding only when required
ianton-ru ddd34ac
Use @subkanthi way
ianton-ru e485a91
Merge branch 'antalya-25.8' into bugfix/antalya-25.8/1536_fix_wrong_p…
ianton-ru 68a487f
Revert "Use @subkanthi way"
ianton-ru File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
enable_url_encodingthrough the wildcard?reparseThe new
enable_url_encodingplumbing is incomplete for URIs that contain a literal?in the key.S3::URIstill reparses those inputs viaPoco::URI(uri_with_question_mark_encode)with the default encoding mode, and the existing gtest atsrc/IO/tests/gtest_s3_uri.cpp:29-33shows that non-versionId?segments are intentionally treated as part ofkey. In a path such as.../a%2Fb?marker, callers fromresolveObjectStorageForPath(..., enable_url_encoding=false)will still decode%2Fback to/after this second parse, so absolute metadata paths that rely on preserved percent-encoding continue to resolve the wrong object.Useful? React with 👍 / 👎.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This methos is called not with any URL, but only with path in S3 or Azure storage. Question mark should be encoded in S3 object name https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html as well as in Azure https://learn.microsoft.com/en-us/azure/devops/organizations/settings/naming-restrictions?view=azure-devops&tabs=git.