Datastore 120 (after 119.2)

'C of A in s': collection = (
	'' = root .'R-A in s'&'in s' .'C'* as $ ( ) // chain: context >'R-A' ?'s' .'C'*
)

// old (accepted: the filter was dropped from the chain):
'ref-c-s': text -> .'C of A in s'[] = from '' [ root >'R-A' >'R-C' ]

// new (the expression takes the same filter):
'ref-c-s': text -> .'C of A in s'[] = from '' [ root .'R-A in s'&'in s' >'R-C' ]
'D via R-A-s': collection = (
	'' = root >'R-A-s'.&'c'.'D'* as $ ( ) // chain: context >'R-A-s' ?'s' >'R-C' .'D'*
)

// old (accepted): an unfiltered reference to some 'A'
'ref-d': text -> .'D via R-A-s'[] = from '' [ root >'R-A'>'R-C'>'R-D' ]

// new:
'ref-d': text -> .'D via R-A-s'[] = from '' [ root >'R-A-s'.&'c'>'R-D' ]
'C of A in s': collection = (
	'' = root .'R-A in s'&'in s' .'C'* as $ ( )
)
'mat': collection -> .'C of A in s' = (
	'' = root >'R-A'.'C'* as $ ( )                // old
	'' = root .'R-A in s'&'in s' .'C'* as $ ( )   // new
)
'c2': collection -> .'c1' = (
	'' = $ .'c2'* >'r1' as $ ( ) // two 'c2' entries may point at one 'c1'
)

// old: no valid 'unique result nodes' found for 'dependency' ( at >'r1' )
// new: no valid 'unique entries' found for 'expression' ( at the branch expression )

For a collection with a key constraint (collection -> .'Source') the step that breaks the uniqueness is marked as well, so the error points at the navigation that has to change.

/* application model: 'X': collection ['k'] { 'k': text  'r': text -> ^ .'C0'[]
**   'rb': text -> ^ .'C0'[] where 'C1 of r' -> ^ .'C1'>[ >'r' ] } */

'E after collection': collection = join - (
	// ERROR: 'r' is not the key of 'X', so two 'X' entries reach the same 'C1' and the 'E' entries repeat
	'' = root .'X'* .'rb'&'C1 of r' .'E'* as $ ( )
)
/* application model: 'Y': collection ['k'] { 'k': text -> ^ .'C0'[]
**   'rb': text -> ^ .'C0'[] where 'C1 of k' -> ^ .'C1'>[ >'k' ] } */

'E after collection by key': collection = join - (
	'' = root .'Y'* .'rb'&'C1 of k' .'E'* as $ ( ) // distinct 'Y' entries find distinct 'C1' entries
)
'D via key': collection = join - (
	'' = root .'Y'* >'k'.'D'[ root >'R-Z' ] as $ ( ) // each 'Y' entry looks up in its own 'D'
)
/* application model: 'A': collection ['k'] 'G': ordered-graph .'first' ( ?'yes' || ?'no'>'prev' ) */

'A via prev': collection -> .'A' = (
	'' = $'r'.'A'* .'first'?'no'>'prev' as $ ( )                       // accepted
)
'A via sib': collection -> .'A' = (
	'' = $'r'.'A'* >'sib' as $ ( )                                     // ERROR: two 'A' entries can have the same sibling
)
'' = $ .'c1a'* .'c1b'* .'kb'&'root' ( ) // ERROR: the rule climbs out of the last collection step
// old
'Documents' = root .'Orders'* as $'order'.'Documents'* as $'document' (

// new
'Documents' =
	root .'Orders'* as $'order'
	.'Documents'* as $'document'
(