Ash Framework
The Elixir backend framework for unparalleled productivity. Declarative tools that let you stop wasting time. Use with Phoenix LiveView or build APIs in minutes for your front-end of choice.
JoinAsh Framework
The Elixir backend framework for unparalleled productivity. Declarative tools that let you stop wasting time. Use with Phoenix LiveView or build APIs in minutes for your front-end of choice.
JoinWindows has problems PendingCodegen after `ash.setup`

Confusion with before_transaction timing and doing changes before manage_relationship
before_transaction
hook. The docs is stating the following execution order for a create action:
```...Conversion of strings with just whitespace when storing in postgres
" "
.
Now, that is not a valid tax number, but we realized that the corresponding DB row has a value of null
instead.
Is this the default behaviour for strings that contain only whitespace?
Is there an option to disable this behaviour and what are the caveats if we do?...manage_relationship not creating many-to-many join records
manage_relationship
to work with a many-to-many relationship where the destination resource uses a non-standard primary key.
Setup
I have a many-to-many relationship between Device
and Pass
through a DeviceRegistration
join table:...Drastic slowdowns
Guides for using ashflow
Aggregates based on resources keep failing
How to upsert multiple rows atomically?
How to load a limited amount of related records (and maybe store as virtual attr?)
Document
:has_many :stats
, and I want to load the accompanying, most recent Stat
only (for each Document
) whenever I fetch a Document
collection.
I tried something like the below but it was not valid--...Child form is not automatically added when a `:union` type attribute has a `value` of `nil`
Form.for_update
on a resource that has a :union
type attribute where the value is nil:
```elixir
form = AshPhoenix.Form.for_update(
%Resource{union: %Ash.Union{type: :custom, value: nil}},...Any pointers on testing authenticated LV's with AshAuthentication Magic Link?
Fails with AshAuthentication.Errors.CannotConfirmUnconfirmedUser
:
```...Actor can create data in other tenant
Edit error messages for Identity
Use of current_tenant throughout app
socket.assigns.current_tenant
in every place where I am about to do a query
```
def mount(_params, _session, socket) do
form =...Type error from ash_postgres for `{:array, :map}`
AshPhoenix nested form not populating
AshPhoenix.Form.add_form
Conditionally run validations
create :provide_feeback
action
When determining whether to get feedback from a user I check if the changeset is valid, i.e. Ash.Changeset.for_create(UserFeedback, :provide_feedback, %{...}, actor: current_user).valid?
...How to return `401 Unauthorized` status when actor is absent in action?
Magic Link login fails due to nil tenant for master user
site_id
is nil
. When I send a Magic Link request for this user, it successfully finds the user and returns a token.
However, the issue occurs when I click on the link — one of the queries throws the following error:
```elixir
[debug] QUERY ERROR source="users" db=0.4ms queue=0.3ms idle=750.5ms
INSERT INTO "users" AS u0 ("id","site_id","confirmed_at","email") VALUES ($1,$2,$3,$4) ON CONFLICT ("email") DO UPDATE SET "email" = EXCLUDED."email", "confirmed_at" = EXCLUDED."confirmed_at" WHERE ((CASE WHEN u0."confirmed_at"::timestamp IS NULL THEN ash_raise_error($5::jsonb) ELSE $6 END)) RETURNING "site_id","confirmed_at","hashed_password","email","id" ["eebf4165-82d2-4c8b-9890-f11808d29c59", nil, ~U[2025-09-05 21:39:04.145886Z], #Ash.CiString<"master@example.com">, "{"input":{"resource":"Elixir.MishkaCms.Accounts.User","confirmation_strategy":"confirm_new_user"},"exception":"AshAuthentication.Errors.CannotConfirmUnconfirmedUser"}", true]...