[python] Fix OSS bucket-in-endpoint mode (PyArrow < 16) corrupting directories via CreateBucket#8710
Merged
JingsongLi merged 1 commit intoJul 23, 2026
Conversation
plusplusjiajia
force-pushed
the
jiajia/pypaimon-oss-legacy-pyarrow6-fix
branch
3 times, most recently
from
July 17, 2026 09:00
f97cad2 to
5772b1f
Compare
plusplusjiajia
force-pushed
the
jiajia/pypaimon-oss-legacy-pyarrow6-fix
branch
3 times, most recently
from
July 17, 2026 10:06
ff0d5c8 to
b010bce
Compare
plusplusjiajia
marked this pull request as ready for review
July 20, 2026 07:02
Contributor
|
Please resolve conflicts. |
…rectories via CreateBucket
plusplusjiajia
force-pushed
the
jiajia/pypaimon-oss-legacy-pyarrow6-fix
branch
from
July 21, 2026 08:00
b010bce to
c4384fa
Compare
Member
Author
@JingsongLi Rebased on master. |
Contributor
|
+1 |
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.
Purpose
In OSS bucket-in-endpoint mode, PyArrow parses the first key segment as a
bucket name, so bucket-level operations target the wrong bucket. (#8695
corrected this mode's boundary from PyArrow < 7 to < 16 and made OSS usable
on 7–15, widening the exposure; this PR rebases on it and keys off the same
_oss_bucket_in_endpointflag.)mkdirs()issued CreateBucket for the database directory, leaving a strayobject that blocks all later create-table mkdirs (
ParentNotDirectoryException).Now a no-op; a missing bucket is still surfaced by a one-time, lock-serialized
bucket-root probe (rejects only on an OSS NoSuchBucket body, fails open
otherwise; probe lock excluded from pickling).
list_status()now fails fast pointing to pyarrow >= 16 or the jindobackend, instead of a misleading NoSuchKey error.
exists()on directories can't be fixed (PyArrow strips marker trailingslashes); documented as a known limitation.
Modern mode (pyarrow >= 16) is unchanged.
Tests
oss_legacy_mode_test.py(13 tests, no credentials) under a tripwire thatfails any unmocked HTTP probe, on pyarrow 6.0.1 and 19.0.1. Verified live
against managed OSS with pyarrow 6.
API and Format
No changes.