Repository navigation
ci: add to the PHPStan baseline the four errors reported on 5.0.x whatever the change - #834
Merged
Merged
Conversation
…tever the change The Static Analysis job fails on 5.0.x for the reasons fixed on 4.3.x by #832: - PHPStan 2.3.7, shipped by the phpqa image since its rebuild of 2026-11-20, reports a mixed value as the condition of the ternaries of the processHeaders() methods of JSONFlattenedSerializer and JSONGeneralSerializer and of the if of MixedPublicAndPrivateKeys; - symfony/dependency-injection 8.2.0 declares the $config argument of ContainerBuilder::prependExtensionConfig() as array<string, mixed>, while ConfigurationHelper::updateJoseConfiguration() passes an array<mixed>. The baseline, generated by castor phpstan-baseline with the current image, gains those four entries and nothing else.
Spomky
added a commit
that referenced
this pull request
Nov 29, 2026
…factory-5.0.x 5.0.x is taken with the PHPStan baseline of #834. #779 reached 5.0.x through 4.3.x, so its merge is resolved as the description of this pull request plans: - the four factories keep the create() of this branch: the branch that throws when header checkers are requested without a header checker manager factory has no case left, and its import goes with it; - the #779 tests that need a factory without header checker manager factory are dropped: headerCheckersAreRefusedWithoutAHeaderCheckerManagerFactory and aLoaderWithoutHeaderCheckersNeedsNoHeaderCheckerManagerFactory in JWELoaderFactoryTest and JWSLoaderFactoryTest, NestedTokenLoaderFactoryTest, the two bundle tests that build a factory with null, and the autowired library factories of the test bundle with the two tests that use them; - theRequestedHeaderCheckersAreGivenToTheLoader stays.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The same repair as #832, on 5.0.x. The Static Analysis job fails on 5.0.x whatever the change, so the tests job, which needs it, is skipped: the drafts #783 and #786 hit it. The last green run on 5.0.x is the one of
893f4c07(2026-11-08).The cause
The same four errors as on 4.3.x, none of them from the code:
JSONFlattenedSerializer::processHeaders();JSONGeneralSerializer::processHeaders();ifofMixedPublicAndPrivateKeys.symfony/dependency-injection8.2.0 declares the$configargument ofContainerBuilder::prependExtensionConfig()asarray<string, mixed>, andConfigurationHelper::updateJoseConfiguration()passes anarray<mixed>.The fix
The baseline, generated by
castor phpstan-baselinewith the current image (phpqa:8.4of 2026-11-28) after a cleancomposer installof 5.0.x, gains those four entries and nothing else. They are the same entries as in #832.Verification
PHPStan on 5.0.x: 4 errors before,
[OK] No errorsafter.