Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[PropertyInfo] fix tests#57837

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
xabbuh merged 1 commit intosymfony:7.2fromxabbuh:pr-57618
Jul 26, 2024
Merged

[PropertyInfo] fix tests#57837

xabbuh merged 1 commit intosymfony:7.2fromxabbuh:pr-57618
Jul 26, 2024

Conversation

xabbuh
Copy link
Member

QA
Branch?7.2
Bug fix?no
New feature?no
Deprecations?no
Issues
LicenseMIT

@xabbuh
Copy link
MemberAuthor

@mtarld@chalasr I could need your help here as I am not sure that this is really the best way to fix the test failures. Basically, this PR reverts#57825. On the7.1 branch this change was necessary as theReflectionExtractor does not pass any resolvers toTypeResolver::create() which in turn means that the newPhpDocAwareReflectionTypeResolver will be used. On the7.2 branch we are explicit and this means that the newPhpDocAwareReflectionTypeResolver is not used (is that intended)?

@chalasr
Copy link
Member

@xabbuh The reasoning behind not wiring thePhpDocAwareReflectionTypeResolver in PropertyInfo is that PropertyInfo has its own implementation for extracting types from phpdoc (PhpStanTypeHelper). I'm not entirely sure but as far as I understand that helper is only used by the to-be-deprecatedPropertyTypeExtractorInterface::getTypes(), not the new type-info basedgetType(). If I'm right, then we should probably just always wirePhpDocAwareReflectionTypeResolver and keep relying onTypeResolver::create() on 7.2.

Mathias is on vacation for 2 weeks so I suggest merging this PR, he will revisit the topic once it gets back.
Thanks for the PRs

@xabbuhxabbuh merged commitda90fe7 intosymfony:7.2Jul 26, 2024
10 checks passed
@xabbuhxabbuh deleted the pr-57618 branchJuly 26, 2024 11:24
@mtarld
Copy link
Contributor

Hey@xabbuh,
TheReflectionExtractor ofPropertyInfo is by definition not aware of phpdoc.
This is the wiring (ie: the service definition) that enable that feature using decoration.

Therefore, we cannot give thePhpDocAwareTypeResolver to theReflectionExtractor, because if so, it won't behave at it used to be.

This is strange that tests are failing in 7.1 though. This might be because of cross-component weird dependencies (ie: property-info in "raw 7.1" and type-info in 7.1 with thePhpDocAwareTypeResolver)

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

@fabpotfabpotfabpot approved these changes

@dunglasdunglasAwaiting requested review from dunglasdunglas is a code owner

Assignees
No one assigned
Projects
None yet
Milestone
7.2
Development

Successfully merging this pull request may close these issues.

5 participants
@xabbuh@chalasr@mtarld@fabpot@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp