I'll pitch in here, as I've been doing a lot of thinking about this issue and ended up writing my own (tiny) tools for handling anomalies, modeled on the very well thought-out https://github.com/cognitect-labs/anomalies categorization.
This is actually a much wider problem and not specific to core.async. Handling anomalies is difficult. It used to be that you would have exceptions and errors which would be thrown, unwinding the stack. This pattern no longer works in asynchronous code, or code that needs to pass anomalies between the server and the client. In practical applications, an anomaly might need to be returned from a function, passed through a `core.async` channel, then thrown, unwinding the stack on the server side, then caught and passed to the client side over a WebSocket, and then displayed to the user there.
Solving this well is not easy. I think my toolkit, iterated and improved over the years, is close to what I need. But I'm pretty sure it wouldn't handle all the real-world use cases yet.
But again, this is not specific to core.async in any way.
My status toolkit just extends the Cognitect anomalies to be statuses, adding ::failed (parameters correct, but could not perform request), ::ok, ::accepted and ::in-progress. It also adds a bunch of utility functions like status/?! (throws the parameter if it's anomaly, returns the parameter otherwise) and macros like status/-?> (threads if an expression is not an anomaly). That's it.
I deliberately avoid trying to do too much here.
I loved ztellman’s “everything must flow” talk on the topic.
I’ve had several PRs accepted into there, I think manifold got a lot of things right, if only it weren’t for Zach leaving the community.
Unfortunately I left the community for similar reasons, I have a different vision of how the language should evolve than the people in charge, but wasn’t as vocal about it. I suspect there are more people like me.
It’s fine, like Rich Hickey said, it’s his project and we have no right to expect anything.
I am forever glad for what Clojure taught me, it made me a much better developer.
AFAIK Zach was just offered well-paying job that was mostly about dealing with Scala, it wasn't about "how the language should evolve"...
This did not align with Cognitect’s centralized stewardship.
This was around the time that there was some quite some commotion in the community around this, with Rich posting his infamous “Open source is not about you” conclusive post, which was in direct response to @cemerick’s Twitter post: https://x.com/cemerick/status/1067111260611850240
He then talks about Aphyr's and Chas Emerick's similar experiences, and laments how in the earliest days, it was still possible to contribute, and how when core development closed off, it was never articulated up front until "Open Source Is Not About You", which is its own can of worms.
Overall, it's a good and nuanced discussion, but it's obvious he wasn't in unreserved love with the language, so I'm not surprised he left.
Yeah, no, I'm not saying Zach wasn't unhappy with the whole core team vs Emerick drama, none of us were. I kinda get it, but also, I don't get it like at all. There are so many tiny details I don't know anything about, but I also feel it was somewhat personal, not really socio-technological (so to speak). Otherwise, we would've maybe seen a big split and a Clojure fork. I see the similar tension (for years) now in Emacs and Org-mode camps. Contributing to core Emacs has similar pain points - specific workflows (no PRs - patches discussed in the mailing list, tone of dismissal toward community-submitted fixes, etc.)
It is really sad that Chas decided to leave slamming the door, makes it almost impossible to imagine him returning and contributing to let's say to Jank, which afaik has none of the hurdles he complained about.
(I've never had to think about the state machine code when debugging and I've done a lot of core async debugging. That part really does seem to just work.)
What I meant was, the use of the go state machine renders certain debugging techniques useless. E.g., stacktraces are less helpful, and js-debugger is pointless, since you can't guarantee the (js-debugger) will get grouped with the state you're trying to debug.
Frequently print/tap is sufficient, but core.async/go narrows your options.
It balloons up the Js artifact, has no inherent error model, and transforms into state machine code that's hard to read/debug if something goes wrong. Plus, the `go` macro encourages overly-large functions, because it can't transform code outside its own sexpr.
As one Cognitect put it, "core.async is beautiful nonsense".