Allow a field accessor alongside FILES' :all()/:groups() GROUP-mode pointer - #274
Merged
Merged
Conversation
…ointer $acme.files.:all().:last():uuid() and $mixed.files.:groups().:last():uuid() now resolve to one field value per (named-file, path) group, instead of raising. The rejection blocking this lumped :manifest() (whole-resource, still Rule 1 territory) together with any field accessor (poolable, exempt from Rule 1 everywhere else in this file). The reduction logic just below the rejection already independently reduces each file_home's own candidates via the pointer regardless of which accessor rides alongside it, and ambiguous_content_read was already correctly written to flag only has_manifest -- the rejection was the one place still treating the two the same. The old comment claimed this "mirrors" ResultsReferenceFinder3's own :all()-grouping restriction, but that was citing RESULTS' original, since-superseded blanket rejection -- RESULTS' current _star_group_and_reduce() already allows a field accessor through here, only rejecting a whole-resource content accessor. FILES had simply never been updated to match. _extract_data() needed no changes: :all()/:groups() bare occupies name_one's entire content by construction, so the trailing field accessor has nowhere to land except name_three, the same already-tested extraction path every other name_three field accessor already uses. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013gPjejPWvbWtjz2dw9h14M
This was referenced Aug 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
$acme.files.:all().:last():uuid()and$mixed.files.:groups().:last():uuid()now resolve to one field value per (named-file, path) group, instead of
raising.
Background
The bucket-list entry read as a single, still-open question -- "GROUP
modes combined with
:manifest()/a field-accessor... not yet built forFILES." Traced
query()'s own GROUP-mode rejection and the reductionlogic just below it before touching anything, rather than assuming the
whole thing needed new machinery:
if pointers: if partitioned: ...) alreadyindependently reduces each distinct
file_home's own candidates viathe pointer, unconditionally -- nothing about it depends on whether
:manifest()/a field accessor is also present.ReferenceResults3.ambiguous_content_readwas already correctlywritten to flag only
has_manifest, neverhas_field_function-- theRule-1-vs-Rule-3 (whole-resource vs. poolable-field) distinction this
fix depends on already existed, just wasn't consistently applied.
ResultsReferenceFinder3's own:all()-grouping restriction -- butthat was citing RESULTS' original, since-superseded blanket
rejection. RESULTS' current
_star_group_and_reduce()already allows afield accessor through here (e.g.
":all():last().invoices:uuid()"resolves fine there, confirmed live before that code was even
written), only rejecting a whole-resource content accessor. FILES had
simply never been updated to match -- a real, confirmable staleness,
not a guess.
_extract_data()needed no changes at all --:all()/:groups()bare occupies name_one's entire content by construction, so the
trailing field accessor has nowhere to land except
name_three, thesame already-tested extraction path every other
name_threefieldaccessor already uses.
What changed
Narrowed
query()'s GROUP-mode rejection frompointers and (has_manifest or has_field_function)topointers and has_manifest--:manifest()(whole-resource) stays rejected here, unchanged, for thesame Rule-1 reasoning it always had; a field accessor is no longer caught
by the same check. That is the entire fix.
Deliberately out of scope:
'*'-traversal's own, separate and muchbroader field-accessor rejection in
_query_star_traversal()-- abigger, still-open gap, unrelated to this fix's
partitioned-plus-pointersscope. Confirmed its own existing tests still pass unchanged.Test plan
into positive assertions -- one correct uuid per group, for both
:all()(ALPHA_MANIFEST's two file_home groups) and:groups()(
MIXED_MANIFEST's two different-depth groups).:manifest()-combined sibling tests (asserting thestill-correct rejection) left unchanged.
tests/references/full tree: 1560 passed.times (identical) -- the known, unrelated SFTP/S3 failures
requiring unset env vars (issue test_nos_server_config_1 crashes with a raw ValueError when SFTP_* env vars are unset, instead of failing clearly #216).
https://claude.ai/code/session_013gPjejPWvbWtjz2dw9h14M