Skip to content

Dedupe the duplicate ComposerAutoloadMap - #382

Merged
Firehed merged 3 commits into
mainfrom
slice/S3.2
Jul 30, 2026
Merged

Dedupe the duplicate ComposerAutoloadMap#382
Firehed merged 3 commits into
mainfrom
slice/S3.2

Conversation

@Firehed

@Firehed Firehed commented Jul 30, 2026

Copy link
Copy Markdown
Owner

Slice S3.2 — Dedupe the duplicate ComposerAutoloadMap

  • Slice: S3.2 (build-manifest.md, Wave 2)
  • Plan step: 0002-execution-plan.md Step 3a(ii) — "dedupe the double ComposerAutoloadMap" (behavior-preserving)
  • RFC: 0001-foundational-architecture.md §4.2 (Symbol Discovery Authority), §5.3 (backends)

What changed

Server::forProject previously built two ComposerAutoloadMap instances from the
same project root: one inside ComposerClassLocator and a second inside
NamespaceCatalogFactory::forProject. Each re-required the three generated Composer
autoload files and built its own ClassLoader.

Both consumers now receive an injected ComposerAutoloadMap, and the composition root
builds exactly one and shares it. ComposerClassLocator no longer knows about project
roots or map construction — it holds the shared map and reads through it (the old
nullable ClassLoader and is_dir guard fall out; an empty map's loader already
returns false for every name).

Acceptance criteria

  • The two production ComposerAutoloadMap instances collapse to a single shared
    instance (one construction site remains in src/, in Server::forProject).
  • Behavior preserved — full suite green, and the Step P parity goldens
    (class-like-lookup, childrenOf) are unchanged.

Candidate closes

None (manifest Closes column is for this slice).

Firehed and others added 3 commits July 29, 2026 17:10
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@codecov

codecov Bot commented Jul 30, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.14%. Comparing base (215ecb4) to head (5c1f38c).
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@             Coverage Diff              @@
##               main     #382      +/-   ##
============================================
- Coverage     98.14%   98.14%   -0.01%     
+ Complexity     1710     1708       -2     
============================================
  Files           109      109              
  Lines          4316     4311       -5     
============================================
- Hits           4236     4231       -5     
  Misses           80       80              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

@Firehed
Firehed merged commit afd1ff5 into main Jul 30, 2026
7 checks passed
@Firehed
Firehed deleted the slice/S3.2 branch July 30, 2026 00:53
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.

1 participant