Problem
The lint job in tests.yaml uses shivammathur/setup-php without specifying a php-version, which means it defaults to whatever PHP version is pre-installed on the GitHub Actions runner. This makes the lint results non-deterministic:
- Different runner images may have different PHP versions
- GitHub periodically updates runner images, changing the default PHP version
- Lint rules may produce different results on different PHP versions (e.g., php-cs-fixer behavior varies by PHP version)
The test job correctly specifies PHP versions via a matrix, but the lint job does not.
Location
.github/workflows/tests.yaml, line 14–15
Current Code
- name: Setup PHP
uses: shivammathur/setup-php@v2
# No php-version specified
Proposed Fix
Pin the PHP version to the project's minimum supported version:
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.2'
tools: composer:v2
Using the minimum supported version (8.2 per composer.json) ensures that lint rules are validated against the lowest common denominator.
Priority
🟢 MINOR — non-deterministic CI behavior; easy fix.
Problem
The lint job in
tests.yamlusesshivammathur/setup-phpwithout specifying aphp-version, which means it defaults to whatever PHP version is pre-installed on the GitHub Actions runner. This makes the lint results non-deterministic:The test job correctly specifies PHP versions via a matrix, but the lint job does not.
Location
.github/workflows/tests.yaml, line 14–15Current Code
Proposed Fix
Pin the PHP version to the project's minimum supported version:
Using the minimum supported version (
8.2percomposer.json) ensures that lint rules are validated against the lowest common denominator.Priority
🟢 MINOR — non-deterministic CI behavior; easy fix.