matrix

kennytilton 2023-01-14T12:01:02.072749Z

Matrix has a new macro with-mx that establishes a pristine MX context, in the form of dynmaic bindings. This has been implemented in Matrix "4.2.0-SNAPSHOT". Other MX libraries have been bumped to pick that up: • mxXHR now at "0.2.0-SNAPSHOT" • mxWeb now at "0.3.0-SNAPSHOT" with-mx is a first step towards connecting two or more runtime MX trees, each with distinct internal state such as the *pulse*, running in different processes, such as a server and client. We cannot resist exploring this with a simulated chat between two chat clients and a chat server, since that is what led FB to abandon in-place state management and invent Flux. No idea how this will turn out. Suspect pragamatic compromises on full-bown data integrity will be needed. This is fine, Cells went quite far before strict integrity was implemented.

🚀 2
kennytilton 2023-01-14T12:02:25.252259Z

ps. This is not a breaking change in any way, so please report any issues sooner than later.

kennytilton 2023-01-14T22:01:42.073969Z

pps. I should have mentioned that this arose because a test was passing only because previous tests had run and had left the pulse at non-zero. Fixing that test was the change made last week, where cell pulse tracking starts at nil. Most tests are now wrapped in (with-mx...). This is not a big deal because models are not very sensitive to existing state -- one of their nice qualities is that they spring to life gracefully in an existing MX. Indeed, the wrapping has yet to break another test, partly because after last week's work I added (cells-init) to all the tests, and that would have flushed out issues.