Akash3121 commented on code in PR #947:
URL: https://github.com/apache/incubator-xtable/pull/947#discussion_r4067675152


##########
xtable-core/src/main/java/org/apache/xtable/kernel/DeltaKernelUtils.java:
##########
@@ -54,7 +56,7 @@ public class DeltaKernelUtils {
    */
   public static boolean tableExists(Engine engine, String basePath) {
     try {
-      Table table = Table.forPath(engine, basePath);
+       Table table = Table.forPath(engine, normalizeTablePath(basePath));

Review Comment:
   Good question. The same consistency is needed when resolving data files, but 
 `normalizeTablePath`  should not be applied directly to each  
`AddFile/RemoveFile`  path. Those paths are normally stored relative to the 
table root in the Delta log and should remain relative. 
   On reads, we resolve them against `table.getPath(engine) ` in  
`DeltaKernelActionsConverter.getFullPathToFile` . 
   On writes, we use the normalized target base path when deriving the relative 
path with  `PathUtils.getRelativePath` . so, no additional normalization of the 
individual file paths is needed.



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