Post

Every time I try to start with ash, I get stuck. I tried with tdd which is very easy in phoenix or rails because the error often guides you what to do next. With ash it's not that obvious.

You should share where you get stuck :) We have a lot of people in the community willing to help, all you have to do is ask. Let us know where you got stuck in a GitHub issue or on ElixirForum/discord 🙇‍♂️

0 reposts0 likes

I appreciate the community's help, but when I get stuck on basic concepts, I know I'll struggle even more with advanced topics. One major blocker was the lack of test examples. While there is a page in the documentation about testing, it doesn't cover important areas like relationships.

My usual approach is to start with a test and let the compiler errors guide me. However, in this case, the errors were so cryptic that I had to abandon the effort. The ash_hq and realworld examples have very few tests, which doesn't help.

To be clear, we don't "blame" folks that have trouble getting started with Ash in any way. Ash's understandability, usability, DX etc. is entirely on me 😁. We have to improve all of the areas you mentioned. I only aim to explain why it's a bit more complex than something like contexts.

Agreed, I'd like to add a test generator. The phoenix generators make a lot of assumptions and ultimately set you up with something far less powerful/flexible than an Ash.Resource. Application logic being a bag of functions is something that IMO helps when you start but that you pay 👇🏻

Please report any cryptic errors as bugs :) We can't fix them if we don't know about them, and often what makes sense to someone w/ experience is cryptic to someone without.