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 2 Support in 11.x #4250

Closed
aweingarten opened this issue Sep 29, 2020 · 7 comments
Closed

Composer 2 Support in 11.x #4250

aweingarten opened this issue Sep 29, 2020 · 7 comments
Labels
Enhancement A feature or feature request

Comments

@aweingarten
Copy link
Contributor

aweingarten commented Sep 29, 2020

Is your feature request related to a problem? Please describe.

Composer2 RC1 was released on September 10, 2020.
https://github.com/composer/composer/releases/tag/2.0.0-RC1

There are major performance benefits to it:
http://hojtsy.hu/blog/2020-sep-28/testing-composer-2-rc1-drupal-9-huge-memory-and-time-savings-and-what-does-it-mean

Describe the solution you'd like
Update the version constraint here:
https://github.com/acquia/blt/blob/11.x/composer.json#L21

To match
https://github.com/acquia/blt/blob/12.x/composer.json#L22

Evaluate other parts of this PR for backport.
https://github.com/acquia/blt/pull/4088/files

Additional context
Support in 11.x is important since:
1: BLT 12.x does not support Drupal 8.
2: Most blt sites rely on Solr
3: Acquia Search is constrained to the 1.x branch of search_api_solr: https://docs.acquia.com/acquia-search/modules/
4: search_api_solr 1.x does not support D9

Therefore Acquia hosted sites using solr cannot upgrade to Drupal 9/BLT 12 till Acquia-Search/Solr-7 reaches GA in Q4/Q1.

@aweingarten aweingarten added the Enhancement A feature or feature request label Sep 29, 2020
@danepowell
Copy link
Contributor

I agree this is necessary, hopefully the backport is straightforward.

@mikemadison13
Copy link
Contributor

A few notes:

  • Fixes #10: adds support for composer 2.x. grasmash/drupal-security-warning#11 (or something similar) will be required to unblock this update as that package doesn't support composer 2.x
  • we need to update dealerdirect/phpcodesniffer-composer-installer to at least ^0.7.0 to support composer 2.x
  • we need to update the root composer.json file to support "composer-plugin-api": "^1.1.0 || ^2.0",
  • we need to add the two new composer plugins (as was done in BLT 12.x)

i did a quick test locally and am blocked by the drupal-security-warning plugin from going farther. @grasmash I dunno if you're willing to merge my PR? it looks smaller / simpler than the one you had opened back in March but based on my experience in the BLT PHPCS plugin what I did there should be both simple and functional.

@danepowell
Copy link
Contributor

Might also want to update Travis CI to use Composer 2 if that's compatible with ORCA. I don't think ORCA directly manages Composer versions, but it might conflict with other Acquia packages. And somewhere a self-update is getting run.

@mikemadison13
Copy link
Contributor

mikemadison13 commented Oct 15, 2020

FYI from: https://github.com/composer/composer/releases

"The current plan is to release a 2.0 final before end of October. It is almost 100% compatible with Composer 1 with the exception of plugins, so please do try it ASAP and report any regression you find. The lock files from v1 can be used by v2 and vice-versa, so don't worry about that."

danepowell added a commit that referenced this issue Oct 16, 2020
* Fixes #4250: updating composer dependencies to support composer 2.x.

* Fixes #4250: adds composer plugins for 2.x.

* Temporarily pinning to drupal/coder 8.3.9.

Co-authored-by: Dane Powell <git@danepowell.com>
@danepowell
Copy link
Contributor

Should be fixed: #4260

@greylabel
Copy link
Contributor

greylabel commented Nov 5, 2020

@danepowell 👋 - any chance you can cut a new 11.x tag with this included? NM, I think I just misread the gitlog.

@danepowell
Copy link
Contributor

Yep should be included in https://github.com/acquia/blt/releases/tag/11.6.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement A feature or feature request
Projects
None yet
Development

No branches or pull requests

4 participants