Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DI] Fixed wrong factory method in exception #29697

Merged
merged 3 commits into from Jan 5, 2019
Merged

[DI] Fixed wrong factory method in exception #29697

merged 3 commits into from Jan 5, 2019

Conversation

wgorczyca
Copy link

Q A
Branch? 4.2
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets #29678
License MIT
Doc PR n/a

When a service definition with a factory defines invalid arguments, the resulting exception message incorrectly specifies the factory constructor instead of the factory method as not having the specified named arguments.

@ogizanagi
Copy link
Member

This could be merged on 4.1 though.

xabbuh and others added 2 commits January 4, 2019 16:09
This PR was merged into the 4.1 branch.

Discussion
----------

remove no longer needed PHP version checks

| Q             | A
| ------------- | ---
| Branch?       | 4.1
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

Commits
-------

7a132fe remove no longer needed PHP version checks
@fabpot fabpot changed the base branch from 4.2 to 4.1 January 5, 2019 07:48
@fabpot
Copy link
Member

fabpot commented Jan 5, 2019

Thank you @wgorczyca.

@fabpot fabpot merged commit 922885c into symfony:4.1 Jan 5, 2019
fabpot added a commit that referenced this pull request Jan 5, 2019
…czyca)

This PR was submitted for the 4.2 branch but it was merged into the 4.1 branch instead (closes #29697).

Discussion
----------

[DI] Fixed wrong factory method in exception

| Q             | A
| ------------- | ---
| Branch?       |  4.2 <!-- see below -->
| Bug fix?      | yes
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #29678   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | n/a <!-- required for new features -->

When a service definition with a factory defines invalid arguments, the [resulting exception message ](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/DependencyInjection/Compiler/ResolveNamedArgumentsPass.php#L70)incorrectly specifies the factory constructor instead of the factory method as not having the specified named arguments.

<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
 - Bug fixes must be submitted against the lowest branch where they apply
   (lowest branches are regularly merged to upper ones so they get the fixes too).
 - Features and deprecations must be submitted against the master branch.
-->

Commits
-------

922885c [DI] Fixed wrong factory method in exception
@xabbuh
Copy link
Member

xabbuh commented Jan 5, 2019

@fabpot Doesn't this fix apply to 3.4 too?

@fabpot
Copy link
Member

fabpot commented Jan 5, 2019

To be honest, I didn't check, just trusted @origaminal's comment to merge it on 4.1.

xabbuh pushed a commit that referenced this pull request Jan 5, 2019
…czyca)

This PR was submitted for the 4.2 branch but it was merged into the 4.1 branch instead (closes #29697).

Discussion
----------

[DI] Fixed wrong factory method in exception

| Q             | A
| ------------- | ---
| Branch?       |  4.2 <!-- see below -->
| Bug fix?      | yes
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #29678   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | n/a <!-- required for new features -->

When a service definition with a factory defines invalid arguments, the [resulting exception message ](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/DependencyInjection/Compiler/ResolveNamedArgumentsPass.php#L70)incorrectly specifies the factory constructor instead of the factory method as not having the specified named arguments.

<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
 - Bug fixes must be submitted against the lowest branch where they apply
   (lowest branches are regularly merged to upper ones so they get the fixes too).
 - Features and deprecations must be submitted against the master branch.
-->

Commits
-------

922885c [DI] Fixed wrong factory method in exception
chalasr pushed a commit that referenced this pull request Jan 5, 2019
* 3.4:
  properly fix tests on PHP 5
  fix tests on PHP 5
  bug #29697 [DI] Fixed wrong factory method in exception (Wojciech Gorczyca)
  Changed gender choice types to color
  remove no longer needed PHP version checks
  Fixed groupBy argument value in DefaultChoiceListFactoryTest
  [HttpKernel] Correctly Render Signed URIs Containing Fragments
  [HttpFoundation] Fix request uri when it starts with double slashes
chalasr pushed a commit that referenced this pull request Jan 5, 2019
* 4.1:
  properly fix tests on PHP 5
  fix tests on PHP 5
  remove doubled dot from exception message
  bug #29697 [DI] Fixed wrong factory method in exception (Wojciech Gorczyca)
  [Intl] make type-hinted arguments nullable
  [DI] Fixed wrong factory method in exception
  Changed gender choice types to color
  remove no longer needed PHP version checks
  remove no longer needed PHP version checks
  Fixed groupBy argument value in DefaultChoiceListFactoryTest
  [HttpKernel] Correctly Render Signed URIs Containing Fragments
  [HttpFoundation] Fix request uri when it starts with double slashes
chalasr pushed a commit that referenced this pull request Jan 5, 2019
* 4.2:
  properly fix tests on PHP 5
  fix tests on PHP 5
  remove doubled dot from exception message
  bug #29697 [DI] Fixed wrong factory method in exception (Wojciech Gorczyca)
  [Intl] make type-hinted arguments nullable
  [DI] Fixed wrong factory method in exception
  Changed gender choice types to color
  Fix unnecessary use
  remove no longer needed PHP version checks
  remove no longer needed PHP version checks
  Fixed groupBy argument value in DefaultChoiceListFactoryTest
  [HttpKernel] Correctly Render Signed URIs Containing Fragments
  [HttpFoundation] Fix request uri when it starts with double slashes
This was referenced Jan 6, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants