Skip to content

docs(recorders): confirm audit_shadow_apis has a real producer (#1148) - #1155

Merged
squid-protocol merged 1 commit into
mainfrom
fix/1148-shadow-apis-sparse-producer-docs
Aug 8, 2026
Merged

squid-protocol merged 1 commit into
mainfrom
fix/1148-shadow-apis-sparse-producer-docs

Conversation

@squid-protocol

Copy link
Copy Markdown
Owner

Summary

Test plan

  • pytest tests/tools_recorders/ tests/security_auditing/test_api_network_map.py tests/core_engine/test_galaxyscope.py — 101 passed
  • python tests/tools/audit_check.py --regenerate — ruff/mypy/dead-key clean (baseline shift only, from the new inline comment moving line numbers)
  • ruff format --check on touched files

🤖 Generated with Claude Code

…er (#1148)

Investigated per #1144's population-scale validation flagging repo_data
.audit_shadow_apis as 99.7% zero across 718 repos. Unlike the dead columns
resolved in #1145/#1147, this one has a real producer: run_api_audit() ->
calculate_api_drift() in full_api_network_map.py, wired through
ecosystem_audits["api_mapper"]["shadow_count"] in galaxyscope.py Phase 10
and read by record_keeper.py. It's exercised by 16 tests in
test_api_network_map.py plus galaxyscope pipeline tests.

The near-zero rate is expected, not a bug: run_api_audit() only computes
drift when a repo ships exactly one auto-discoverable, parseable
OpenAPI/Swagger spec (any other candidate count returns 0 via
"no_swagger"/"ambiguous" status). Most repos in a general-purpose corpus
never satisfy that precondition, so a near-zero aggregate rate reflects
how rarely repos carry a matching machine-readable API spec at all.

Documents the finding in the full_api_network_map wiki page and an inline
schema comment, and adds a record_keeper test asserting the
ecosystem_audits.api_mapper.shadow_count -> audit_shadow_apis DB column
wiring explicitly (previously only exercised incidentally).

Co-Authored-By: Claude Sonnet 5 <[email protected]>
@github-actions

github-actions Bot commented Aug 8, 2026

Copy link
Copy Markdown
Contributor

🐦‍⬛ Muninn Security Scan

✅ No security issues found.

🐦‍⬛ Powered by Muninn · Skald Lab

@squid-protocol
squid-protocol merged commit df77e21 into main Aug 8, 2026
28 checks passed
@squid-protocol
squid-protocol deleted the fix/1148-shadow-apis-sparse-producer-docs branch August 8, 2026 12:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

audit_shadow_apis (repo_data) is 99.7% zero with no confirmed producer -- investigate before fixing

1 participant