action :bulk_destroy_user_notification, :boolean do
argument :ids, {:array, :uuid}, allow_nil?: false
run fn input, context ->
ids = input.arguments.ids
__MODULE__
|> Ash.Query.filter(id in ^ids)
|> Ash.bulk_destroy(:destroy, %{}, return_errors?: true)
|> dbg
{:ok, true}
end
end
Sorry for the late reply
Ash.bulk_destroy(:destroy, %{}, return_errors?: true, strategy: :atomic) #=> %Ash.BulkResult{
status: :error,
errors: [
%Ash.Error.Invalid{
errors: [
%Ash.Error.Invalid.NoMatchingBulkStrategy{
resource: Dentallog.Accounts.UserNotification,
action: :destroy,
requested_strategies: [:atomic],
not_stream_reason: nil,
not_atomic_batches_reason: "Not in requested strategies",
not_atomic_reason: "AshArchival.Resource.Changes.ArchiveRelated does not implement `atomic/3`",
footer: nil,
splode: Ash.Error,
bread_crumbs: [],
vars: [],
path: [],
stacktrace: #Splode.Stacktrace<>,
class: :invalid
}
]
}
],
records: nil,
notifications: nil,
error_count: 1
}
The bulk_destory itself succeeded, but the
not_atomic_batches_reason: "Not in requested strategies",
not_atomic_reason: "AshArchival.Resource.Changes.ArchiveRelated does not implement `atomic/3`",
I am getting the above error. It seems to be related to AshArchival.






















