Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Composer v2 compatibility #768

Merged
merged 3 commits into from
May 26, 2020
Merged

Composer v2 compatibility #768

merged 3 commits into from
May 26, 2020

Conversation

JeppeKnockaert
Copy link
Contributor

@JeppeKnockaert JeppeKnockaert commented May 16, 2020

Q A
Branch master for features and deprecations
Bug fix? no
New feature? yes
BC breaks? no
Deprecations? no
Documented? yes
Fixed tickets #756

This pull request adds support for Composer v2. I've also added the version of composer to the test matrix, so both versions are tested.

  • Wrong namespaces don't get autoloaded anymore in Composer v2, so I fixed that as well.
  • Paratest has not created a version supporting composer v2 yet, this is why I included the dev requirement
  • friendsofphp/php-cs-fixer has an open PR for composer v2 (Updated composer.json to support composer/semver:2.* PHP-CS-Fixer/PHP-CS-Fixer#4935), but doesn't even seem to be needed anymore in the dev requirements, so I left it out. The alternative would be to include a phar version of php-cs-fixer for Travis.
  • hirak/prestissimo should not be installed anymore for composer v2 (this is now built-in), see update composer plugin api version hirak/prestissimo#218
  • I don't think we need to use deactivate/uninstall (for now), because cleanup is already done by using events. Maybe things can be cleaned up / optimized after composer v1 has been dropped.

@veewee
Copy link
Contributor

veewee commented May 26, 2020

Thanks for the PR! It looks really nice.

The error is related to a broken openssl on appveyor, will have to take a look at why it fails before I merge it in.

@JeppeKnockaert
Copy link
Contributor Author

Thank you @veewee. It seems every recent PR has this issue. I believe it is linked to this PHP issue, which was fixed in 7.4.6RC1 according to the comments in that issue (https://bugs.php.net/bug.php?id=79589).

@veewee
Copy link
Contributor

veewee commented May 26, 2020

yeah .. maybe best to hardcode it to a previous 7.4 version for now?

@veewee veewee added this to the 0.18.1 milestone May 26, 2020
@veewee veewee merged commit 9830ee7 into phpro:master May 26, 2020
@veewee
Copy link
Contributor

veewee commented May 26, 2020

Thanks again!

@JeppeKnockaert JeppeKnockaert deleted the composer-v2-compatibility branch May 26, 2020 14:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants