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

Do not specify PHP version in root composer #162

Merged
merged 1 commit into from
Oct 17, 2024

Conversation

RobjS
Copy link
Contributor

@RobjS RobjS commented Oct 17, 2024

The intention of the root composer file is just to ensure that Whippet is available for use in local development (or in automated workflows) without needing to be globally installed.

Any PHP version specified here neither indicates what PHP version the app is intended to run on (as none of the dependencies here are used in deployed code), nor should affect the output of any Whippet commands run.

So, for maximum compatibility as we're in the midst of the PHP7-to-8 switchover, let's not indicate a PHP version here at all.

Copy link
Contributor

@snim2 snim2 left a comment

Choose a reason for hiding this comment

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

This is fine but we may also need to update the PHP8 docs in govpress-technical-docs to match

@RobjS
Copy link
Contributor Author

RobjS commented Oct 17, 2024

I've looked into this a bit more, and I don't think specifying the PHP version in this file is actually as problematic as I first thought - there are plenty of repo's where the version is set to 8.2 and the automated workflows (set to run in 7.4) still complete successfully, because the latest version of Whippet works in both. And even though it doesn't really do anything, it does serve as some kind of useful marker as to whether a repo should be on PHP 7 or 8. So now I'm thinking maybe we should:
a) Change this PR so it bumps the PHP version to 8.2, rather than removing it altogether; and
b) Tidy the root composer.json in David Sainsbury so it just contains Whippet, rather than the additional dependencies (which I don't think are really doing anything?)

@snim2
Copy link
Contributor

snim2 commented Oct 17, 2024

@RobjS sure. I'd change davids first, just to validate anything that goes into the template

Although this won't have any effect on the PHP version the app runs on
(it just determines the version used to install Whippet), it's a useful
indicator of what version we're using in the app, and it should be
consistent with that.
@RobjS RobjS force-pushed the chore/do-not-specify-php-version-in-root-composer branch from ba23b91 to a3218c5 Compare October 17, 2024 13:31
@RobjS RobjS merged commit aecd144 into main Oct 17, 2024
9 checks passed
@RobjS RobjS deleted the chore/do-not-specify-php-version-in-root-composer branch October 17, 2024 13:32
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.

2 participants