JingsongLi commented on code in PR #10190:
URL: https://github.com/apache/paimon/pull/10190#discussion_r4178250801


##########
paimon-python/pypaimon/read/reader/format_vortex_reader.py:
##########
@@ -47,7 +47,11 @@ def __init__(self, file_io: FileIO, file_path: str, 
read_fields: List[DataField]
         if store_kwargs:
             from vortex import store
             vortex_store = store.from_url(file_path_for_vortex, **store_kwargs)
-            vortex_file = vortex_store.open()
+            # vortex 0.70.0 S3Store (and the other object stores) have no
+            # ``.open()``; the supported entry point is ``vortex.open(path,
+            # store=...)``. Passing the store carries the endpoint/credentials
+            # the OSS path needs while vortex resolves the object.
+            vortex_file = vortex.open(file_path_for_vortex, store=vortex_store)

Review Comment:
   [P1] Pass a path relative to the explicitly configured store
   
   In Vortex 0.70.0, `store.from_url(full_file_uri)` sets the object's key as 
the store prefix, and `vortex.open(path, store=...)` interprets `path` relative 
to that store; it does not strip the full URI here. This call therefore appends 
the URI to the file prefix. With the actual SDK and this reader, 
`oss://127/fixture.vortex` produced a signed HEAD request for 
`/fixture.vortex/s3%3A/127/fixture.vortex` rather than `/fixture.vortex`, and 
failed with 404. The usual `oss://bucket/db/table/file.vortex` input has the 
same duplicated-path problem, so the OSS read workflow remains unusable despite 
replacing the nonexistent `store.open()` API. A control retaining the same 
file-prefixed store and calling `vortex.open('', store=...)` reads all 500 
fixture rows/nulls and passes filtering, row-index, shard and projection 
checks. Please use an empty relative path with the current file-prefixed store, 
or construct a bucket-root store and pass only the relative object key, and 
cover this with a r
 eal pinned-SDK reader test; the fake `vortex.open` assertion currently accepts 
the incorrect full URI.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to