Conversation
There was a problem hiding this comment.
Graphify reviewed this change.
Worth a look — the grounded gate found no coupling regressions or blocking issues, but 1 advisory finding(s) below merit a look before merge.
Formal verification. 2 change(s) tested, no difference found (not proven).
Graphify review — findings
Extracts direct block attributes during Terraform parsing, recording bounded primitive/list/object literals under each node's attributes key via _collect_direct_attributes and _parse_attr_value, with control-char stripping and caps for value length, list items, and attribute count (_METADATA_MAX_ATTRIBUTES). Makes the serve layer search and surface those attributes: _node_attributes_text flattens them into normalized/tokenized search fields, _score_query awards a new _ATTRIBUTE_MATCH_BONUS tier for term hits, and node detail and subgraph rendering emit truncated, sanitized attribute summaries.
Worth a look
- Subgraph context emits sensitive attribute values —
graphify/serve.py:1146· Escalate · high- agreed by 2 of 2 members but NOT verified (no proof, no reproducing execution) — consensus is not a verdict; needs human review
Analysis details — impact, health, verification
Impact & health
Graphify review
Impact — 2601 functions depend on the 214 functions this change touches.
Health — this change adds coupling hotspots:
- new:
extract()— 645 callers, 45 callees - new:
_rebuild_code()— 129 callers, 54 callees - new:
build_merge()— 76 callers, 14 callees - new:
_extract_generic()— 18 callers, 29 callees - new:
extract_bash()— 45 callers, 10 callees - new:
to_json()— 58 callers, 7 callees - new:
extract_js()— 85 callers, 4 callees - new:
extract_xaml()— 19 callers, 17 callees - …and 56 more — each is listed as a finding
Verification — 2601 functions in the blast radius were not formally verified this run (proofs are advisory here).
Gate & verification
graphify gate
PASS — objectively clean (no health regressions, tests not run — proofs not run this pass (advisory)). Grounded, not self-assessed.
Advisory (not blocking):
- verification_scope: 1358 function(s) in the blast radius were not formally verified this run
Test selection
Test selection
69 of 286 test file(s) selected (24%) via static blast radius.
tests/test_astro_extraction.py— impacttests/test_atomic_writes.py— impacttests/test_benchmark.py— impacttests/test_benchmark_raw_graph.py— impacttests/test_build.py— impacttests/test_build_merge_dedup_scope.py— impacttests/test_build_merge_hyperedges_and_prune.py— impacttests/test_build_merge_shrink_guard.py— impacttests/test_callflow_html.py— impacttests/test_carried_hyperedge_remap.py— impacttests/test_cjs_module_extension.py— impacttests/test_cli_export.py— impacttests/test_community_labels_skill.py— impacttests/test_confidence.py— impacttests/test_corrupt_graph_json.py— impacttests/test_cpp_nested_and_cli.py— impacttests/test_cross_extension_reexport_self_cycle.py— impacttests/test_dotnet.py— impacttests/test_export.py— impacttests/test_export_control_characters.py— impacttests/test_extract.py— impacttests/test_file_label_disambiguation.py— impacttests/test_global_add_tag_inference.py— impacttests/test_global_graph.py— impacttests/test_go_qualified_resolution.py— impacttests/test_god_nodes_exclude_hubs.py— impacttests/test_hyperedge_roundtrip.py— impacttests/test_hypergraph.py— impacttests/test_import_extension_resolution.py— impacttests/test_indirect_dispatch.py— impacttests/test_indirect_dispatch_assign_return.py— impacttests/test_indirect_dispatch_getattr.py— impacttests/test_ingest.py— impacttests/test_issue_3472_source_file_collision.py— impacttests/test_js_exported_scalar_bindings.py— impacttests/test_labeling.py— impacttests/test_languages.py— impacttests/test_markdown_code_spans.py— impacttests/test_mcp_ingest.py— impacttests/test_multigraph_diagnostics.py— impacttests/test_multilang.py— impacttests/test_paths.py— impacttests/test_pipeline.py— impacttests/test_prs.py— impacttests/test_prune_sweeps_orphans.py— impacttests/test_python_underscore_resolution.py— impacttests/test_query_induced_edges.py— impacttests/test_query_mcp_direction.py— impacttests/test_query_names_its_graph.py— impacttests/test_rationale.py— impact- … and 19 more
Selection is safe under the controlled-regression assumption; always-run tests + a periodic full run are the backstops. Advisory — it never changes the check verdict.
Formal verification
Could not verify: Could not verify extract\_terraform.
The verifier did not have enough to check extract\_terraform, so it is saying so rather than guessing. No false assurance is the whole point.
Guarantee: No guarantee either way, this is an honest abstention, not a pass.
Note: Reason: no capturable inputs from the test suite; property tier: parameter `path` is annotated `Path` — outside the synthesizable primitive/collection set
Could not verify: Could not verify \_build\_server.
The verifier did not have enough to check \_build\_server, so it is saying so rather than guessing. No false assurance is the whole point.
Guarantee: No guarantee either way, this is an honest abstention, not a pass.
Note: Reason: no capturable inputs from the test suite; property tier: not verifiable: all 23 sampled inputs raised on both versions — the function never executed, so 'no divergence' would be vacuous
No difference found (not proven): No behavior difference found in \_node\_search\_text (not a proof).
The verifier ran both versions of \_node\_search\_text on many inputs and saw identical behavior every time. Strong evidence the change is safe, but evidence, not a proof.
Guarantee: Empirical: differential testing (both versions run on many generated inputs). A divergence on an untested input remains possible, so this is 'no counterexample found', not 'proven equivalent'.
Note: An input the sampler did not try could still differ.
Could not verify: Could not verify \_score\_query.
The verifier did not have enough to check \_score\_query, so it is saying so rather than guessing. No false assurance is the whole point.
Guarantee: No guarantee either way, this is an honest abstention, not a pass.
Note: Reason: no capturable inputs from the test suite; property tier: not verifiable: all 45 sampled inputs raised on both versions — the function never executed, so 'no divergence' would be vacuous (mostly TypeError — names the real obstacle, not a sampling gap)
No difference found (not proven): No behavior difference found in \_subgraph\_to\_text (not a proof).
The verifier ran both versions of \_subgraph\_to\_text on many inputs and saw identical behavior every time. Strong evidence the change is safe, but evidence, not a proof.
Guarantee: Empirical: differential testing (both versions run on many generated inputs). A divergence on an untested input remains possible, so this is 'no counterexample found', not 'proven equivalent'.
Note: An input the sampler did not try could still differ.
· 64 more finding(s) on lines outside this diff (see the check run).
…the graph (#3644 follow-up) #3644 persists HCL block attributes into node metadata, which is serialized to graph.json verbatim and surfaced to the model over MCP (query/get_node) with no sanitize_metadata pass. A hardcoded credential in a .tf file (password, db_password, aws_secret_access_key, client_secret, a connection string, ...) would leak. Redact the VALUE of any attribute whose key names a secret while keeping the key visible, so instance_type/ami queries still work and a user can still see THAT a secret is set. Recurses into map values so a nested secret in a tags/connection map is redacted too. Also notes Terraform block attributes in the _AST_CACHE_SCHEMA 4 comment (they are newly-cached facts covered by the same bump #3653 introduced). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Summary
Fixes #3625 by preserving direct Terraform/HCL attributes on their owning block nodes and exposing them to Graphify's search/query context.
Changes
attributesmapping on resource/data/module/variable/output/provider nodes.referencesanddepends_onedges unchanged.Validation
pytest tests/test_terraform.py— 15 passedpytest tests/test_serve.py tests/test_build.py tests/test_dedup.py— 343 passedgit diff --check— cleanThe existing Windows-only path-separator failure in
tests/test_terraform_modules.pyremains unrelated to this change.