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

[BUGS-5651] Workaround issue with preUpdate script. #470

Merged
merged 6 commits into from
Jan 25, 2023
Merged

Conversation

kporras07
Copy link
Collaborator

No description provided.

@kporras07 kporras07 requested a review from a team as a code owner January 23, 2023 16:54
@kporras07 kporras07 changed the title [BUGS-5651] Run composer update twice. [BUGS-5651] Update platform.php before running composer update. Jan 24, 2023
exec("composer --working-dir=$siteDir require --no-update pantheon-systems/quicksilver-pushback");

if (Comparator::greaterThanOrEqualTo($version, '9.5.0')) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it be okay to just change this in the template projects? What if the platform.php version is already > 8.1.13? What about php_version in pantheon.yml?

Copy link
Collaborator Author

@kporras07 kporras07 Jan 24, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is just a stopgap solution to allow it to run composer update without downgrading to 9.4.4 (which was happening because 9.5.0 raised PHP requirement to >=8 (or 8.1?)).

Once composer update runs, it will run the preUpdate code and will set the final version as expected.

Would it be okay to just change this in the template projects?

Template project is drupal-composer-managed, not sure if we want to do that, my guess is not.

What if the platform.php version is already > 8.1.13? What about php_version in pantheon.yml?

This made me think: why not running the already existing pre-update-script in drupal-composer-managed? That would be way better. In order to do that, I need https://github.com/pantheon-systems/drupal-composer-managed/pull/14 to be merged into default. I think that's probably the best solution.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I found this to not be true unless we deploy to pantheon-upstreams which we don't want right now.

So I made a workaround here and it's working now

@kporras07 kporras07 requested review from greg-1-anderson and a team January 24, 2023 15:02
@kporras07 kporras07 changed the title [BUGS-5651] Update platform.php before running composer update. [BUGS-5651] Workaround issue with preUpdate script. Jan 25, 2023
@kporras07 kporras07 merged commit 432c36b into 3.x Jan 25, 2023
@kporras07 kporras07 deleted the bugs-5651-2 branch January 25, 2023 14:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants