fix(catalog): recurse into loop bodies when extracting references - #45
Merged
Conversation
SHOW CALLEES/REFERENCES missed microflow calls, entity creates, retrieves, and page shows inside LOOP bodies because buildReferences() only iterated top-level ObjectCollection.Objects without recursing into LoopedActivity.ObjectCollection. Extract collectActionActivities() helper that recursively collects ActionActivity objects from nested LoopedActivity bodies. Fixes #39 (secondary issue: SHOW CALLEES missing loop body calls)
ako
approved these changes
Mar 27, 2026
ako
left a comment
Collaborator
There was a problem hiding this comment.
Clean fix, good test coverage, model PR scope.
ako
added a commit
that referenced
this pull request
Jul 27, 2026
This was referenced Jul 27, 2026
ako
pushed a commit
that referenced
this pull request
Jul 29, 2026
#45 (alter-page.md): document three ALTER PAGE limitations the ledger project hit, with the recommended "bind at page creation" pattern — SET cannot rewire a button's action; REPLACE cannot reuse a widget name from the subtree being replaced (built before the old is removed → collision); a footer is a marker and is not addressable by its author-given name (serialized as footer1). These are design constraints, so the guidance is to define save/reset microflows before the page and bind buttons at creation rather than altering the page afterward. #46 (theme-styling.md): DataGrid2 renders role=grid/row/gridcell <div>s, not table/tr/td — CSS and Playwright must target the ARIA roles; and column `Size` is a flex weight, not pixels — set a min-width on [role='grid'] with overflow-x:auto. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JXnEgoc2NQP1Y2TWMCMXC4
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
SHOW CALLEES/REFERENCESmissed microflow calls, entity creates, retrieves, and page shows insideLOOPbodiesbuildReferences()inbuilder_references.goonly iterated top-levelObjectCollection.Objectswithout recursing intoLoopedActivity.ObjectCollectioncollectActionActivities()helper that recursively collects allActionActivityobjects from nested loop bodies (including deeply nested loops)Regarding issue #39
The issue reports two problems:
emitLoopBody()incmd_microflows_show_helpers.go:431-493) with passing roundtrip test (TestRoundtripMicroflow_LoopWithBody). The reporter's specific case may involve a different edge case — requesting their project file to reproduce.Partially fixes #39
Test plan
collectActionActivities(): top-level, inside loop, nested loops, nil collection, nil actionsmake buildsucceeds🤖 Generated with Claude Code