composer: fix incomplete path-repo closures (sugar-glow/stickers/wishlist) + harden checker for transitive gaps#880
Merged
Merged
Conversation
…list) + harden checker for transitive gaps The candy-forms extraction added a transitive sugarcraft/candy-forms dep to sugar-bits. Three downstream libs that consume sugar-bits never had the new transitive path-repos added to repositories[], so a fresh composer install could not resolve candy-forms (the one lib not yet on Packagist) and failed. sugar-stickers surfaced this as 27 "Bits\Viewport not found" test errors. Completed the full transitive sugarcraft/* path-repo closure for sugar-glow, sugar-stickers, and sugar-wishlist. Hardened tools/check-path-repos.php to walk the FULL transitive require graph (not just direct requires) and report the introducing dependency path, so a gap several hops deep is caught instead of passing as "closure clean". Default mode treats Packagist-published deps as resolvable; --strict-closure demands a local path-repo for the entire closure. ## Test plan - Checker BEFORE fix: flags sugar-glow/sugar-stickers/sugar-wishlist (each: missing path-repo for candy-forms via -> sugar-bits -> candy-forms). - Checker AFTER fix: "closure clean" (exit 0). - Fresh composer install + full phpunit per lib (rm -rf vendor composer.lock): - sugar-glow: install clean, 66 tests, 141 assertions, OK - sugar-stickers: install clean, 60 tests, 107 assertions, OK (27 Viewport errors gone) - sugar-wishlist: install clean, 70 tests, 180 assertions, OK - Full-repo resolve scan: no "STILL BROKEN" lines. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Not up to standards ⛔🔴 Issues
|
| Category | Results |
|---|---|
| CodeStyle | 3 minor |
🟢 Metrics 0 complexity · 0 duplication
Metric Results Complexity 0 Duplication 0
NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
candy-formsextraction added a transitivesugarcraft/candy-formsdep tosugar-bits. Three downstream libs that consumesugar-bits(sugar-glow,sugar-stickers,sugar-wishlist) never had the new transitive path-repos added to theirrepositories[], so a freshcomposer installcould not resolvecandy-forms(the one monorepo lib not yet on Packagist) and failed.sugar-stickerssurfaced this as 27Bits\Viewport not foundtest errors.sugarcraft/*path-repo closure for all three libs (addedcandy-formsplus the rest of each lib's closure:candy-pty,candy-sprinkles,candy-zone,honey-bounce,candy-palette, and thecandy-shinesub-tree forsugar-glow).tools/check-path-repos.php: it now walks the full transitivesugarcraft/*require graph (previously only direct requires) and reports the introducing dependency path, so a gap several hops deep — exactly this class of bug — is caught instead of passing as "closure clean". Default mode treats Packagist-published deps as resolvable (matches how Composer actually resolves today);--strict-closuredemands a local path-repo for the entire closure regardless,--no-networkskips the Packagist probe.improvements.md§3.7 (found+fixed) and updated theCONTRIBUTING.mdline describing the checker.Checker before/after
Before (flags the 3 broken libs):
After:
Test plan
rm -rf vendor composer.lock && composer install+ fullvendor/bin/phpunitper lib:Bits\Viewport not founderrors gone)composer update --dry-runover every lib): noSTILL BROKENlines.🤖 Generated with Claude Code