Skip to content

IBX-11907: Added php-version input to composer-install action and Rector workflow - #115

Merged
alongosz merged 2 commits into
mainfrom
ibx-11907-composer-install-php-version-input
Sep 5, 2026
Merged

IBX-11907: Added php-version input to composer-install action and Rector workflow#115
alongosz merged 2 commits into
mainfrom
ibx-11907-composer-install-php-version-input

Conversation

@alongosz

@alongosz alongosz commented Sep 4, 2026

Copy link
Copy Markdown
Member

Caution

  • Drop TMP commits before merging (rector.yml points composer-install at this branch for testing)
🎫 Issue IBX-11907

Description:

actions/composer-install passes ${{ matrix.php }} straight to setup-php instead of exposing an input. Any caller without a PHP matrix ends up with an empty php-version, and setup-php silently installs the latest stable PHP.

The reusable rector.yml workflow is exactly such a caller: Rector run 33925477235 via ibexa/cloud#14 installed PHP 8.5.10. A fleet scan (2026-09-05) found 23 rector.yaml callers across 14 packages (core, migrations, test-fixtures, dam-user, fieldtype-richtext-rte, connector-anthropic, connector-ai-assistant, connector-raptor, connector-seenthis, admin-ui-extras, async-content-publishing, mercure, translations, fastly-forwarded-host), plus the new ones from the IBX-11778 rollout. All of them run on whatever setup-php considers latest ATM.

  • [GHA] Added optional php-version input to actions/composer-install. When empty, it falls back to matrix.php, so existing callers behave exactly as before (BC).
  • [GHA] Exposed an optional php-version input in the reusable rector.yml workflow and passed it to composer-install. No default on purpose: an empty value keeps the current behavior (setup-php default, ATM PHP 8.5.x).

Note

No caller changes required. Rector callers that want a stable PHP version can now opt in with with: php-version: '8.3'.

For QA:

No manual QA required. Tested via a throwaway harness on ibexa/gha-testing@ibx-11907-rector-harness, run 33928247591:

  • 🟢 Rector workflow called with php-version: '8.3' installed PHP 8.3.33
  • 🟢 Rector workflow called without php-version kept current behavior (installed PHP 8.5.10)
  • 🟢 actions/composer-install without php-version in a matrix job (8.3, 8.4) still used matrix.php (installed PHP 8.3.33 and 8.4.25)

Documentation:

No documentation required.

🤖 Generated with Claude Code

alongosz and others added 2 commits September 5, 2026 01:04
The action passed matrix.php straight to setup-php. Callers without a
PHP matrix ended up with an empty version and setup-php silently
installed the latest stable PHP. The input is optional and falls back
to matrix.php when empty, so existing matrix-based callers are not
affected.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The Rector job has no matrix, so composer-install resolved an empty
PHP version and setup-php picked its default (PHP 8.5.10 observed in
https://github.com/ibexa/cloud/actions/runs/33925477235). The input is
passed through to composer-install with no default on purpose: current
behavior stays unless a caller opts in with e.g. php-version: '8.3'.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@alongosz
alongosz force-pushed the ibx-11907-composer-install-php-version-input branch from 1b5cc39 to 7a6d0eb Compare September 5, 2026 00:00
@sonarqubecloud

sonarqubecloud Bot commented Sep 5, 2026

Copy link
Copy Markdown

@alongosz
alongosz merged commit 3796ff9 into main Sep 5, 2026
5 checks passed
@alongosz
alongosz deleted the ibx-11907-composer-install-php-version-input branch September 5, 2026 17:22
@alongosz

alongosz commented Sep 5, 2026

Copy link
Copy Markdown
Member Author

Merged to unblock IBX-11778 pending wave of PRs. Can address remarks, if any, as a follow-up.

This was referenced Sep 6, 2026
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.

1 participant