It looks like ordering is important here and I don't think set preserves order. Also, why do we want to compress FileChanges that are the same, suppose we have this sequence:
/a is added
/a is deleted
/a is added again
With this implementation we could only get one add and one deletion so we would think the file doesn't exist but it does.
If this introduced a bug that wasn't detected by test, we should probably add a test for this too :)
Originally posted by @leandro-lucarella-frequenz in #42 (comment)
It looks like ordering is important here and I don't think
setpreserves order. Also, why do we want to compressFileChanges that are the same, suppose we have this sequence:/ais added/ais deleted/ais added againWith this implementation we could only get one add and one deletion so we would think the file doesn't exist but it does.
If this introduced a bug that wasn't detected by test, we should probably add a test for this too :)
Originally posted by @leandro-lucarella-frequenz in #42 (comment)