robertwb commented on a change in pull request #16066:
URL: https://github.com/apache/beam/pull/16066#discussion_r758655094



##########
File path: sdks/python/apache_beam/dataframe/io.py
##########
@@ -521,10 +535,15 @@ def create_tracker(self, restriction):
       return beam.io.restriction_trackers.UnsplittableRestrictionTracker(
           tracker)
 
-  def process(self, readable_file, tracker=beam.DoFn.RestrictionParam()):
+  def process(
+      self, readable_file, path_indices, tracker=beam.DoFn.RestrictionParam()):
     reader = self.reader
     if isinstance(reader, str):
       reader = getattr(pd, self.reader)
+    start_index = (
+        tracker.current_restriction().start +
+        path_indices[readable_file.metadata.path] *
+        10**int(math.log(2**64 // len(path_indices), 10)))

Review comment:
       This becomes an error in the exabyte range (e.g. millions of TB-sized 
files). That's probably a ways off, but just in case I added a check. 




-- 
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