JingsongLi commented on code in PR #8136:
URL: https://github.com/apache/paimon/pull/8136#discussion_r3519595155
##########
paimon-python/pypaimon/read/table_scan.py:
##########
@@ -42,10 +42,23 @@ def __init__(
self.predicate = predicate
self.limit = limit
self.partition_predicate = partition_predicate
+ self._read_type = None
self.file_scanner = self._create_file_scanner()
def plan(self) -> Plan:
- return self.file_scanner.scan()
+ auth_result = self._auth_query()
+ plan = self.file_scanner.scan()
+ if auth_result is not None:
+ plan = auth_result.convert_plan(plan)
Review Comment:
This auth wrapping is only applied by `plan()`, but `scan_with_stats()`
below still returns the raw scanner plan. `ReadBuilder.explain()` uses
`scan_with_stats()`, and Daft explain derives routing from those split details;
the actual Daft scan path sees `QueryAuthSplit` and falls back to pypaimon,
while explain will still report native Parquet for the same auth-enabled scan.
Please apply the same `_auth_query().convert_plan(...)` logic in
`scan_with_stats()` while preserving the `ScanStats`, and add an explain
regression for an auth-enabled table.
--
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]