You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
search/build never see integration-contributed components #5258
astryx search and astryx build build their component candidate list from gatherComponents(coreDir) in api/search/search.mjs, which only ever scans @astryxdesign/core. A project's configured integrations (astryx.config's integrations array) are never part of that pool — not behind a flag, just absent from the code path.
This means a component that only exists in an integration (no core equivalent, no name collision) is invisible to both search and build, even though component --list and component <Name> already resolve it correctly via the same loadedIntegrations data component/list.mjs already uses.
Repro
Register an integration contributing a component, e.g. OtpField (no core equivalent):
astryx component OtpField — finds it.
astryx component --list — finds it, tagged with its owning package.
astryx search "otp" — returns unrelated doc/template results, never mentions it.
astryx build "collect a verification code" — recommends TextInput instead.
For coding agents this is the same class of problem AGENTS.md's "discover, don't guess" workflow is meant to prevent: an agent following that workflow through search/build will never reach an integration's own components, and will reach for whatever core component looks closest instead.
Fix
I have a PR ready: splits gatherComponents into gatherCoreComponents (unchanged) and gatherIntegrationComponents, the latter reusing loadIntegrationsSafely + discoverIntegrationComponents — the same functions component/list.mjs already uses for component --list. gatherComponents merges both; its call site now passes cwd alongside coreDir so the integration lookup has a project root to resolve from.
Confirmed against current main: gatherComponents(coreDir) (search.mjs line 361) calls discoverComponents(coreDir) only, no path to loadedIntegrations/discoverIntegrationComponents at all, matching what component/list.mjs already does for component --list. Same gap in the search-results build at line 594-604 (coreDir is the only thing threaded through).
Since you already have a PR ready, I'll leave it to you rather than duplicate, happy to review once it's up. The gatherCoreComponents/gatherIntegrationComponents split you describe sounds like the right shape, reusing loadIntegrationsSafely matches how component/list.mjs already solved this exact problem.
Activity
HelloOjasMutreja commentedon Aug 21, 2026
Confirmed against current main:
gatherComponents(coreDir)(search.mjs line 361) callsdiscoverComponents(coreDir)only, no path toloadedIntegrations/discoverIntegrationComponentsat all, matching whatcomponent/list.mjsalready does forcomponent --list. Same gap in the search-results build at line 594-604 (coreDiris the only thing threaded through).Since you already have a PR ready, I'll leave it to you rather than duplicate, happy to review once it's up. The
gatherCoreComponents/gatherIntegrationComponentssplit you describe sounds like the right shape, reusingloadIntegrationsSafelymatches howcomponent/list.mjsalready solved this exact problem.