Granola-Team / mina-indexer

The Mina Indexer is a re-imagined version of the software collectively called the "Mina archive node."
Apache License 2.0
18 stars 10 forks source link

Watched directory block reading fails when file is a hard link #1219

Closed jhult closed 2 months ago

jhult commented 2 months ago

https://en.wikipedia.org/wiki/Hard_link

jhult commented 2 months ago

This might a code area to explore: https://github.com/Granola-Team/mina-indexer/blob/main/rust/src/block/precomputed.rs#L191

robinbb commented 2 months ago

Ingestion works - files that are in the blocks directory when the mina-indexer starts. But, files that are added later are not recognised.

jhult commented 2 months ago

This may be a dupe of #1218

n1tranquilla commented 2 months ago

The watch dir appears to be broken. @jhult and I cannot find any evidence that watch dir is ingesting blocks.

jhult commented 2 months ago

macOS may ignore hard links: https://github.com/notify-rs/notify/issues/374

robinbb commented 2 months ago

Check for faulty code, mishandling of the staking directory command line option, I suggest.