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

Drop helperset usage in favor of the DependencyFactory #898

Merged
merged 18 commits into from
Jan 14, 2020

Conversation

goetas
Copy link
Member

@goetas goetas commented Dec 29, 2019

Q A
Type improvement
BC Break -
Fixed issues #743 (and partially #726)

Summary

Even if symfony/symfony#27647 did not pass, it is a good idea to not depend on the symfony helperset feature. The doctrine's DependencyFactory is a better way to get command dependencies.

  • code
  • tests
  • documentation

@goetas goetas force-pushed the remove-helperset-usage branch 4 times, most recently from f4e8975 to dd84fbd Compare January 10, 2020 06:57
@goetas goetas removed the WIP label Jan 10, 2020
@goetas
Copy link
Member Author

goetas commented Jan 10, 2020

this is ready for review

@goetas goetas force-pushed the remove-helperset-usage branch 2 times, most recently from f038112 to ece01e0 Compare January 10, 2020 07:29
@@ -2,8 +2,9 @@

declare(strict_types=1);

namespace Doctrine\Migrations\Configuration\Exception;
namespace Doctrine\Migrations\Configuration\Configuration\Exception;
Copy link
Member

Choose a reason for hiding this comment

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

Is this on purpose? I find the double Configuration in the namespace rather strange.

Copy link
Member Author

Choose a reason for hiding this comment

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

It is intentional. I'm also not very happy, but was done to give come structure. Currently there are 3 types of configurations: Migration configs, Connection configs and Entity manager configs. So the idea was to keep all of them in the same folder, but in 3 subfolders.
If you have another idea, will be happy to change it.

Copy link
Member

Choose a reason for hiding this comment

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

How about Doctrine\Migrations\Configuration\(EntityManager|Connection|Migration)? Configuration\Configuration seems odd, and doesn't convey why we need the additional subnamespace.

lib/Doctrine/Migrations/DependencyFactory.php Outdated Show resolved Hide resolved
lib/Doctrine/Migrations/DependencyFactory.php Outdated Show resolved Hide resolved
docs/en/reference/custom-configuration.rst Outdated Show resolved Hide resolved
@goetas goetas force-pushed the remove-helperset-usage branch from 3d4ffea to 1f96b53 Compare January 12, 2020 06:32
@goetas goetas requested review from alcaeus and greg0ire January 12, 2020 06:32
@goetas goetas force-pushed the remove-helperset-usage branch from 8c05a66 to 442c9a8 Compare January 13, 2020 05:58
@goetas
Copy link
Member Author

goetas commented Jan 13, 2020

@greg0ire all your comments have been addressed except the one where the conversation is not marked as resolved.

Copy link
Member

@alcaeus alcaeus left a comment

Choose a reason for hiding this comment

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

Still not happy about the Configuration\Configuration namespace bit, but feel free to create an issue for that and refactor it in a separate PR if you want to work on other things first. Rest LGTM!

@greg0ire greg0ire merged commit 7406096 into doctrine:master Jan 14, 2020
@greg0ire
Copy link
Member

Thanks @goetas !

@goetas goetas deleted the remove-helperset-usage branch March 22, 2020 11:02
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.

4 participants