Chris
10/17/2025, 8:06 PMmacosx I used the FreeBSD tool paste to build a command. paste, unfortunately, did not implement macOSX policy regarding carriage returns, which apparently macOSX was using on the file.
As a result, paste injected \r characters (0x0D) that even vim was insensitive to (although tr was, so it does appear the file was valid, in some sense), and which bypassed python sanitization to be deposited directly in the datalake unescaped, in raw form.
When querying these files via the lakectl tool, they are not accessible. A lakectl fs ls chokes on the result, yielding a corrupted `common_prefix`:
common_prefix 1536.1350/
/ommon_prefix 1539.1980
-- here you can see the `\r`s are not handled.
As a result I can neither rename nor access the files. Has anyone encountered this problem, and if you have, is there a solution?Chris
10/17/2025, 8:06 PMChris
10/17/2025, 8:12 PMpython intentionally (they are always escaped by python). But since tr repaired the file and vim displayed it correctly, it looks like it was an ordinary situation that should be quietly tolerated (as it was in vim).
So I've added secondary sanitization, but different layers of lakefs are handling the filename properly and improperly (from what I can tell).Iddo Avneri
10/17/2025, 8:29 PMlakectl local to clone the data locally, run a script to sanitize and rename the files, and then commit the changes back?
I’d definitely recommend doing this in a separate branch first, just to be safe.Chris
10/17/2025, 8:31 PMChris
10/17/2025, 8:31 PMNiro
10/17/2025, 8:51 PMChris
10/17/2025, 9:25 PMxyz$'\r' # where 'xyz' is the name they should beIddo Avneri
10/17/2025, 9:29 PMAriel Shaqed (Scolnicov)
10/19/2025, 7:03 AMlakefs://... URLs really are URLs, so you can encode a carriage return in them as %0D. I would try e.g.
lakectl fs rm '<lakefs://my-repo/branch/common_prefix%0D1536.1350/>'. I would hesitate to add another encoding for doing this, as it would be nonstandard.
Would a better error message have helped? The current error message is:
path URI malformed lakefs URI
Error executing command.Iddo Avneri
10/20/2025, 2:54 PMChris
10/20/2025, 3:14 PM