witheve / Eve

Better tools for thought
http://witheve.com
Apache License 2.0
7.16k stars 257 forks source link

Fix/watcher interface multiplicity #838

Closed joshuafcole closed 7 years ago

joshuafcole commented 7 years ago

Fix #834.

The watcher interface had a subtle but extremely dangerous flaw in the context of heavily-stratified programs. It attempted to maintain the export index as a stream, which meant that it would occasionally discard impactful changes or emit paradoxical changes. To fix this, we simply hold on to all exported facts until the entire transaction has completed, and then manage the export index post-collapse. Thanks to @thSoft for catching and reporting the issue and @ibdknox for helping me discard a very large number of red herrings.