Skip to content

Disable platform.php composer config for lowest/latest jobs #79

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

Conversation

weierophinney
Copy link
Member

Q A
Documentation no
Bugfix no
BC Break maybe?
New Feature yes
RFC yes
QA no

Description

Per the February 2022 TSC meeting, when doing composer update operations, we should honor the current PHP version, and not the one listed in the platform.php configuration.

Renovate-Bot needs a platform.php setting to use when updating composer.lock to ensure that it updates to dependencies supported by our minimum supported PHP version.
However, when running CI, if such a setting is present, we'll never test against dependency versions supported by later PHP versions, and hence it needs to be removed when testing against latest and lowest dependencies.

Per the February 2022 TSC meeting, when doing `composer update` operations, we should honor the current PHP version, and not the one listed in the platform.php configuration.

Signed-off-by: Matthew Weier O'Phinney <[email protected]>
@weierophinney weierophinney added this to the 1.18.0 milestone Feb 7, 2022
case $DEPS in
lowest)
echo "Installing lowest supported dependencies via Composer"
# Disable platform.php, if set
composer config --unset platform.php
Copy link
Member

Choose a reason for hiding this comment

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

Fancy, didn't know of this shortcut!

Copy link
Member Author

Choose a reason for hiding this comment

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

@rdohms taught me to avoid manually updating composer.json whenever possible, and the config subcommand is our friend here. :)

Better, it doesn't emit an error if the setting isn't present, which ensures the script continues running in those cases.

@Ocramius Ocramius changed the title Disable platform.php config for lowest/latest jobs Disable platform.php composer config for lowest/latest jobs Feb 7, 2022
@Ocramius Ocramius merged commit 73f2243 into laminas:1.18.x Feb 7, 2022
@weierophinney weierophinney deleted the feature/disable-platform-php-during-jobs branch February 8, 2022 16:51
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