Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/janedbal/composer-class-ambiguity-test
Composer does not check class duplicates properly
https://github.com/janedbal/composer-class-ambiguity-test
Last synced: about 1 month ago
JSON representation
Composer does not check class duplicates properly
- Host: GitHub
- URL: https://github.com/janedbal/composer-class-ambiguity-test
- Owner: janedbal
- Created: 2024-10-02T15:35:31.000Z (4 months ago)
- Default Branch: master
- Last Pushed: 2024-10-04T10:17:41.000Z (4 months ago)
- Last Synced: 2024-12-12T16:09:42.313Z (about 1 month ago)
- Language: PHP
- Homepage:
- Size: 4.88 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
> [!CAUTION]
> Since composer `2.8.1`, the issue described below was [fixed](https://github.com/composer/composer/pull/12148)## Composer does not check class ambiguity properly
- If you have class duplicate in your project, composer may not warn about that.
- This repository shows an example of that.
- Since composer 2.8, you can use `--strict-ambiguous`, but that still does not solve this issue
- Currently, you can ensure no ambiguity is present by [shipmonk/name-collission-detector](https://github.com/shipmonk-rnd/name-collision-detector)### How to reproduce
```sh
composer install
composer dump -a --strict-ambiguous
echo $?
php run.php
```### How to see all real collisions
```sh
composer require --dev shipmonk/name-collision-detector
vendor/bin/detect-collisions src tests
```### Related GitHub issue
- https://github.com/composer/composer/issues/12140