Zach Daniel
745aa6e85f
chore: update changelog
2024-09-03 22:38:02 -04:00
Zach Daniel
032a2426d5
chore: release version v3.4.2
2024-09-03 22:28:20 -04:00
Zach Daniel
a2cfaa5fe0
chore: use a better config name
2024-09-03 22:24:24 -04:00
Zach Daniel
06cd509e1f
chore: make the new policy behavior opt-in with config
2024-09-03 22:22:46 -04:00
Zach Daniel
82230f1a89
fix: don't clean calc deps that may need to be reused
2024-09-03 19:00:28 -04:00
Zach Daniel
3c90063c40
fix: fix upsert condition for ets bulk creates
2024-09-03 18:01:43 -04:00
Andreas Donig
de0f72b475
Fix: honor bulk upsert condition ( #1432 )
...
* Require Ash.Expr to make sure upsert_conflict/1 is available
* Make sure it correctly tests opts[:upsert_condition] for nilness
* Make sure the base changeset also adheres to the upsert condition
* Revert the changes so we can show the problem with a test case
* Add a test case that shows what the problem is
* Add the upsert_condition filter to the base changeset again
* Change the way the test checks because bulk_create/4 does not return unchanged records
2024-09-03 16:23:12 -04:00
Zach Daniel
abef09148e
fix: honor return_destroyed?
in soft destroy actions
...
fixes #1433
2024-09-02 14:16:25 -04:00
Zach Daniel
1002d8178e
improvement: make read policies more consistent, always preferring to filter over raise
...
docs: document access type
2024-09-02 14:11:09 -04:00
Zach Daniel
6f2a14715d
improvement: show an explanation when no policies apply
2024-09-02 12:48:36 -04:00
pinetops
dd44d5dcf2
improvement: Add a case for handling mapsets in Filter.map ( #1427 )
2024-09-02 12:41:57 -04:00
Zach Liss
f1874a708d
docs: Fix typo in authorize-access-to-resources howto ( #1431 )
2024-09-02 10:58:33 -04:00
Barnabas Jovanovics
0dc3a75aaf
use Ash instead of Domain module for read in docs ( #1430 )
2024-09-02 10:58:04 -04:00
pinetops
2c754f90a6
improvement: Cache always selected fields and use mapsets for building select list ( #1428 )
...
* Add attribute_names function on Info that returns MapSet
And use that when calculating select lists.
2024-09-01 17:06:51 -04:00
pinetops
cdbb0c4608
Normalize approach to caching attributes/calculations/relationships ( #1425 )
2024-09-01 12:44:45 -04:00
Zach Daniel
c7eaabdb2e
fix: correctly handle return values of batch callbacks ( #1424 )
...
* improvement: factor out static branches at compile time
---------
Co-authored-by: Hannes Wüthrich <hannes.wuethrich@zebbra.ch>
2024-08-31 15:53:14 -04:00
Zach Daniel
8ba9eeb3b4
fix: properly clean calculation dependency values, and don't unload them with lazy?
2024-08-31 15:32:54 -04:00
Zach Daniel
926762cf38
improvement: do not eager evaluate filters for read action policies
2024-08-31 14:34:29 -04:00
Zach Daniel
4adddcdd69
Revert "improvement: make authorization failures behave consistently across reads"
...
This reverts commit ffa37d0c95
.
2024-08-30 19:51:46 -04:00
Zach Daniel
ffa37d0c95
improvement: make authorization failures behave consistently across reads
2024-08-30 19:45:28 -04:00
Rebecca Le
cc55670c7f
bug: Add failing test for lazy-reloaded calculations that aren't loading their dependencies ( #1420 )
2024-08-30 18:29:38 -04:00
Zach Daniel
b99ff3b3a0
chore: update docs
2024-08-30 18:27:48 -04:00
Zach Daniel
ec250ab7a4
fix: ensure that async limiter is cleared up front
2024-08-30 18:25:15 -04:00
Zach Daniel
bb07fa19a9
fix: ensure that update_defaults are set on streaming updates
...
fixes #1418
2024-08-30 18:12:30 -04:00
Zach Daniel
13a7c87daa
fix: honor skip_global_validations?
in bulk actions
2024-08-30 17:44:00 -04:00
Zach Daniel
cb80df9ed8
test: test new default keyset pagination
2024-08-30 17:36:10 -04:00
Zach Daniel
f4dc9620ae
improvement: make default page type configurable, defaulting to :offset
...
The getting started guide and ash installer set it to `:keyset`
closes #1413
2024-08-30 17:18:50 -04:00
Zach Daniel
9b0fb15ecb
fix: honor the countable
option in pagination
...
the default unfortunately had to be changed to `true`, given that it was being ignored before
chore: clean up error declarations
2024-08-30 15:34:40 -04:00
Zach Daniel
0007d0e60a
fix: return proper data shape when doing a read in a transaction
...
closes #1410
2024-08-30 15:19:38 -04:00
pinetops
3859571fae
Improve caching of relationships and add caching of calculations ( #1417 )
...
Note that this likely demonstrates some broken code elsewhere,
demonstrated by the need to accept other types other than string and atoms.
2024-08-30 14:59:35 -04:00
Jinkyou Son
e2731ecd2d
Replace PaginationNotSupported exception with ActionRequiresPagination exception ( #1411 )
2024-08-30 13:11:46 -04:00
Zach Daniel
c7b861c511
fix: ensure that from
is properly set on all notifications
...
fix: typo in bulk destroy not clearing ash_started_transaction state
2024-08-30 11:46:33 -04:00
dependabot[bot]
7702cdc2f6
chore(deps): bump the production-dependencies group with 3 updates ( #1422 )
2024-08-30 00:00:19 -04:00
Ben Swift
6c66fcd423
fix typo in Policies doc ( #1423 )
2024-08-30 00:00:02 -04:00
pinetops
f63e86f9d6
improvement: add pattern for Ash.Query.Call in Filter.map ( #1416 )
2024-08-28 14:55:55 -04:00
Hannes Wüthrich
4a75743812
Fix generated change/3
function when only implementing batch_change/3
( #1415 )
2024-08-28 08:04:52 -04:00
Zach Daniel
55f1ead24f
fix: do not add relationship filter when building relationship authorization
2024-08-26 11:49:00 -04:00
Zach Daniel
04382cbc53
fix: don't list telemetry handlers if app is compiling
2024-08-26 10:01:39 -04:00
Zach Daniel
dbe825b504
fix: handle no_attributes when joining lateral join relationship data
2024-08-23 11:27:03 -04:00
dependabot[bot]
6de12a19a4
chore(deps): bump the production-dependencies group with 2 updates ( #1404 )
2024-08-22 23:40:45 -04:00
Andreas Donig
bc400929fb
docs: Make sure there is a caret in front of each atomic_ref occurence ( #1403 )
2024-08-22 14:27:47 -04:00
Andreas Donig
986d6e6467
docs: Fix an error in the changeset action lifecycle example ( #1402 )
2024-08-22 09:15:22 -04:00
Zach Daniel
05feea14ef
chore: avoid emitting read spans when only loading data
2024-08-21 20:47:37 -04:00
Dmitry Maganov
8d4a4b055a
fix: do not call tracer set_metadata
with span type that it ignores ( #1400 )
2024-08-21 19:43:40 -04:00
Zach Daniel
1f3059b5bf
fix: traverse calculated relationships when rewriting transient calculation values
...
chore: clean up sort call to `function_exported?`
2024-08-21 19:34:19 -04:00
Zach Daniel
b841eaf54c
chore: add tests for accept & some opts improvements
2024-08-21 11:58:11 -04:00
Zach Daniel
d593e3cee9
improvement: error at compile for bypasses that will have no effect
...
chore: remove unused `checks` field from `%Ash.Policy.Authorizer.Policy{}`
2024-08-20 21:30:55 -04:00
Zach Daniel
7cf38273fa
improvement: prevent unnecessary calls to Ash.load
2024-08-20 11:55:46 -04:00
Zach Daniel
48507eac13
chore: run proper callback and test that we call the loading callback
2024-08-20 10:25:50 -04:00
Zach Daniel
51f57b6390
chore: pass context to load relationships
2024-08-20 10:18:01 -04:00