-
-
Notifications
You must be signed in to change notification settings - Fork 453
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
Deprecate type comment attribute from configuration #947
Conversation
b122810
to
058c221
Compare
note that in the Configuration class, we should deprecate passing |
and yes, removing an option while keeping the behavior of a non-default value requires a 2-step deprecation process. We did that multiple times in Symfony already. |
I was wondering how to best solve the use-case of having
With that in mind, I don't think we need to deprecate anything in the |
Yeah, for 1.x, your deprecations cover all cases here. |
058c221
to
311a153
Compare
311a153
to
1ab34f3
Compare
1ab34f3
to
ba3f5bb
Compare
Supersedes #628.
The
commented
attribute will be removed in 2.0. To allow people to migrate properly and not have to deal with deprecations until actually switching to 2.0, the default value ofcommented
changes fromtrue
tonull
so we know whether a type was explicitly marked as commented or not. The connection factory now takes into account whether a type itself requires a comment and only explicitly marks it as commented ifDepending on the scenario, appropriate deprecation notices will be thrown according to the table below:
commented
attributecommented: true
commented: false
commented: false
commented
attribute will have to be dropped for 2.0.Note that users that want to use a type without comments will have to explicitly specify
commented: false
in the configuration. At the same time, we will not be triggering a deprecation notice for this case. This is because in order to maintain BC, not setting thecommented
option will implicitly mark the type as commented, even when the type itself doesn't do so. Users that want to have uncommented types will have to remove thecommented
attribute when upgrading to DoctrineBundle 2.0. If anyone has a suggestion how to best solve this, please let me know as I didn't find any alternative.