Skip to content

test(github): Test on PHP 8.3 and Drupal 10.2.x#1389

Merged
klausi merged 6 commits intodrupal-graphql:8.x-4.xfrom
klausi:test-php-8.3
Jan 28, 2024
Merged

test(github): Test on PHP 8.3 and Drupal 10.2.x#1389
klausi merged 6 commits intodrupal-graphql:8.x-4.xfrom
klausi:test-php-8.3

Conversation

@klausi
Copy link
Copy Markdown
Contributor

@klausi klausi commented Jan 28, 2024

No description provided.

@klausi klausi merged commit 4be1232 into drupal-graphql:8.x-4.x Jan 28, 2024
@klausi klausi deleted the test-php-8.3 branch January 28, 2024 12:38
@klausi klausi added the 4.x label Jan 28, 2024
drupal-core: '10.1.x'
drupal-core: '10.2.x'
phpstan: '0'
# We only need to run PHPStan once on the latest PHP version.
Copy link
Copy Markdown
Contributor

@Kingdutch Kingdutch Jan 29, 2024

Choose a reason for hiding this comment

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

@klausi I usually recommend running PHPStan on the lowest supported PHP version rather than the highest since it prevents people from accidentally using syntax of newer PHP versions that would break PHP compatibility.

I see that's already different from what we did, but we might want to consider changing it.

Alternatively we may want to specify a PHP version in the phpstan config: https://phpstan.org/user-guide/docker#different-php-version%3F

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

hm, but does phpstan check for PHP version syntax? I usually like to run it on the newest version so that we make our code as forward compatible as possible. PHP syntax errors are then hopefully caught by running the tests on the older PHP versions.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Yeah the underlying PHP-parser knows and the stubs might be different with some functions not available until newer versions (although they might still be discovered through shims).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants