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

DX-5154: drupal-environment-detector new release broke btl project #4583

Closed
jonedadev opened this issue Aug 23, 2022 · 7 comments
Closed

DX-5154: drupal-environment-detector new release broke btl project #4583

jonedadev opened this issue Aug 23, 2022 · 7 comments
Labels
12.x Affects or applies to 12.x Support A support request

Comments

@jonedadev
Copy link

jonedadev commented Aug 23, 2022

FATAL ERROR
Getting this error after release 1.5.0 of drupal-environment-detector project got live.

Fatal error: Declaration of Acquia\Blt\Robo\Common\EnvironmentDetector::getSiteName($site_path) must be compatible with Acquia\DrupalEnvironmentDetector\AcquiaDrupalEnvironmentDetector::getSiteName(string $site_path): ?string in /var/lib/tugboat/vendor/acquia/blt/src/Robo/Common/EnvironmentDetector.php on line 238

@jonedadev jonedadev added the Bug Something isn't working label Aug 23, 2022
@github-actions github-actions bot changed the title drupal-environment-detector new release broke btl project DX-5154: drupal-environment-detector new release broke btl project Aug 23, 2022
mikemadison13 added a commit to mikemadison13/blt that referenced this issue Aug 23, 2022
@mikemadison13
Copy link
Contributor

@jonedadev can you please confirm the version of BLT you are running? I was going to fix this, then noticed that as of 13.5.2 it should already be resolved. see https://github.com/acquia/blt/blob/main/src/Robo/Common/EnvironmentDetector.php#L113 and https://github.com/acquia/blt/blob/main/src/Robo/Common/EnvironmentDetector.php#L252.

@ayalon
Copy link

ayalon commented Aug 24, 2022

It completely bricks any drupal site using BLT 12. I'm currently on 12.8.2 and got drupal-environment-detector via composer update.

@mikemadison13
Copy link
Contributor

ah ok. so first, I'd suggest you upgrade to BLT 13. but i'll open a PR for BLT 12 and see if we can cut a release that marks the 1.5.0 environment detector incompatible.

@mikemadison13
Copy link
Contributor

mikemadison13 commented Aug 24, 2022

in the interim (and in case we don't cut a 12.x release) you can add the following to your composer.json to fix it:

"conflict": {
        "acquia/drupal-environment-detector": ">=1.5.0",
      }

or you can pin the require section to 1.4.1. either or.

@danepowell
Copy link
Contributor

danepowell commented Aug 24, 2022

BLT 12 is unmaintained and has not had a release in 18 months. More breakage of this nature is very likely to happen.

See https://docs.acquia.com/blt/#releases-and-versioning,

Acquia only provides support for the most recent Acquia BLT release.

BLT 13 should be a relatively painless upgrade, it's only a major release because some functionality was moved to plugins: https://github.com/acquia/blt/releases/tag/13.0.0

@ayalon
Copy link

ayalon commented Aug 24, 2022

Upgrading to the required BLT Version 13.5.2 required Drush 11 which again implies a lot of dependencies. So an upgrade can be quite a pain.
But thanks for the heads-up. I'm currently updating all the needed dependencies.

@mikemadison13 mikemadison13 added Support A support request 12.x Affects or applies to 12.x and removed Bug Something isn't working labels Aug 24, 2022
@danepowell
Copy link
Contributor

We'll fix this in #4587

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
12.x Affects or applies to 12.x Support A support request
Projects
None yet
Development

No branches or pull requests

4 participants