Title
#help
s

Sander Hartlage

10/31/2022, 1:11 PM
hey folks, is there a way to create a commit without any changes, similar to git's
--allow-empty
option? we're ingesting third-party data into lakefs and making a daily commit; it would be helpful to commit even without changes so that history shows there were no new files that day
Or Tzabary

Or Tzabary

10/31/2022, 1:13 PM
hey @Sander Hartlage ! thanks for explaining the use case, let me check that for you
1:22 PM
@Sander Hartlage digging a little deeper, the commit requires files to change in order to execute
1:23 PM
you can use tags to point to a specific commit without adding new files, but that doesn't support your usecase
1:24 PM
you could modify a single file (i.e updated_at) which will contain the timestamp, this will let you commit as you provide the command least one file
1:24 PM
does this support your use-case?
s

Sander Hartlage

10/31/2022, 1:25 PM
yeah, that should work great
1:26 PM
that's probably an even better solution that allowing empty commits
1:26 PM
every time i've had to use
--allow-empty
was because i was doing something crazy
Or Tzabary

Or Tzabary

10/31/2022, 1:26 PM
happy to hear that
1:27 PM
let me know if there's anything else we can help with
Ariel Shaqed (Scolnicov)

Ariel Shaqed (Scolnicov)

10/31/2022, 8:32 PM
An option to allow empty commits would have been useful for me, too. The upcoming LakeFSOutputCommitter has to perform commits; having to special-case this (and similar things when merging no changes) is a pain... That will probably lead to more special area in downstream automated applications. I am not sure why we block these commits. They can help with any automated process. For instance if I have gc enabled, I might want a daily commit on my trunk so I can always see data from the last 2 weeks + 1 commit. But I cannot have it if there is no new data.