Repository navigation
feat(managed): filter and project retained member views - #7968
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
[Medium impact] The reviewed changes appear safe to merge; no actionable defects were found. SummaryAdds exact member filters and collection-specific column choices to retained views shared by CLI and MCP.
Diagram%%{init: {'theme': 'neutral'}}%%
flowchart LR
CLI[CLI request] --> Shared[Shared analysis-view service]
MCP[MCP request] --> Shared
Parent[Authenticated parent Evidence] --> Shared
Shared --> Filter[Match recorded names and types]
Filter --> Page[Page known matches]
Page --> Project[Keep requested columns and identity]
Project --> Result[View Evidence with source coverage]
Filter --> Unknown[Count unresolved candidates]
Unknown --> Result
Reviews (1) · Last reviewed commit: "test(managed): guard relationship endpoi..." · Reviewed by Greptile |
|
CI baseline audit for c126364:
The remaining CI shards are still running/queued; any feature-related finding will be addressed before merging. |
|
Merged as cf9f010 after all eight portable test shards passed. The aggregate report contains 38,069 passing tests and only the previously audited native-provider baseline failure; formatting failures likewise reproduce on the tested main. The owner-authorized bypass was used for those unrelated failures. No human-review declaration was filled on behalf of the owner. |
Summary
Fixes #7282.
inspect_analysis_viewcan filter retained managed members by exact names/declaring types and project columns. CLI and MCP share this domain implementation; callers can retrieve signatures without the method bodies and IL anchors.Problem and expected behavior
Previously, finding members in a large retained assembly required paging unrelated full rows or inspecting types again. For example:
{"source":{"kind":"retained-evidence","evidence_id":"<parent>"},"view":{"kind":"managed-members","collection":"methods","names":["ParseNumber","ParseReadNumber"],"declaring_types":["Newtonsoft.Json.JsonTextReader"],"fields":["name","declaring_type","signature"]}}This returns matching rows in source order, with tokens, defining tokens, metadata offsets, original
source_index, module/MVID and source coverage. Body facts remain accessible by explicitly selectingbodyor reading the complete parent Evidence.Change and scope
Collection-specific contracts and a single shared selector own filtering/projection. Exact filters intersect before paging; empty lists match nothing. Only returned rows are projected. Fields-only pages visit only their requested slice; filtered pages count matches in one pass without materializing the matched inventory. Existing immutable-parent validation/cache is reused; no new index or cache.
Supported filter meanings are documented explicitly, including MemberRef parent types and call/field-access targets. Display strings are not reparsed. Schema definitions have one owner, separate from projection. Existing validation scenarios retain their assertions through smaller verification helpers.
Existing offline Evidence-query authority; a separate maintainer scope decision is not applicable. No provider, execution, installation or dependency change.
Contract and boundary impact
managedMemberViewSchemasandmanagedMemberView; existing CLI/MCP dispatch uses the same implementation.source_countdescribes producer-returned rows;unresolved_filter_rowspreserves candidates with unknown requested facts. Known-match pagination never establishes absence among unknown/unexamined rows. Parent Evidence stays unchanged.Expected effects:
Evidence and regression coverage
Validation performed
npm run check:fast: typecheck, lint and module-boundary validation passed.npm run docs:check: six tasks plus nine README checks passed. Formatting and diff checks passed.Completed-task measurements
Pinned main
4671947c9→ feature056348be2: 24 alternating fresh MCP tasks, three repetitions per corpus/workflow. Each discovers schemas, inspects/retains the complete assembly once, answers two successive questions and closes. Both profiles are compact, with application/managed/session families; all RPC frames, catalogs and text/structured replies are counted.Catalog cost is included: 36,697 → 36,786 estimated tokens. The new large task uses 4 tool calls versus 9/15/68; the small task uses 4 versus 3/4/4. Small elapsed ranges overlap (about 3.1–3.4 s). For the two large retained queries, the fastest previous composition took 371–416 ms versus 46 ms; whole-task startup/inspection still dominates, and best-case total timings overlap.
Tokenx counts are transport estimates, not model billing/rendered context. OS files and default CLI code caches were warm; sessions were fresh and each summary warmed its immutable parent. Cold OS/code-cache-disabled costs were not measured. Linux 10ms process-family RSS includes client/server/sampler; CPU uses wait4 plus sampler CPU. Observation/NDJSON costs are included. Heaps were capped at 2 GiB and family guard at 1.5 GiB/150 s; no stop occurred in the 24 paired tasks. No local tests/builds ran concurrently.
Full schemas were verified separately. One old large full-profile paging probe hit the 1.5 GiB family guard and was stopped; no survivors or target changes remained. It is an incomplete baseline, excluded from comparisons. Completed full-profile new workflows peaked at approximately 988/1,096 MiB. Fixtures, raw traces and benchmark scripts remain outside Git.
Compatibility, safety, and release
No intended breaking change or migration. Runtime verification: Linux x64, Node 24.22.1. Windows/macOS execution and the issue's private assembly remain unverified. Assemblies were parsed statically, never loaded or executed. No package/release metadata change.
Author readiness
Human owner:
Before merge
type(scope): outcome.