Beta phase evaluation
Issue category | Bug because the entity conversion option is misleadingly named. |
---|---|
Disruption | Disruption is minimal, core only uses this option once in a real life scenario and once in a test. |
Problem/Motivation
It is possible to use the use_current_language upcasting option to opt out of override-free upcasting on admin paths. For example #2137595-26: 'Create @name' page title uses override-free configuration (eg. not localized) instead of the overridden configuration (eg. localized) used that to load an entity type properly in a possibly admin context.
Proposed resolution
Rename this option to with_config_overrides or something along those lines.
Remaining tasks
Commit.
User interface changes
None.
API changes
The incorrectly named use_current_language option is renamed to with_config_overrides.
Comment | File | Size | Author |
---|---|---|---|
#19 | interdiff.txt | 3.58 KB | Gábor Hojtsy |
#19 | 2405939-with-overrides-param-19.patch | 4.7 KB | Gábor Hojtsy |
#12 | interdiff.txt | 438 bytes | olli |
#12 | 2405939-with-overrides-param-12.patch | 4.65 KB | olli |
#6 | interdiff.txt | 1.11 KB | Gábor Hojtsy |
Comments
Comment #1
Gábor HojtsyProposed patch using "with_overrides" language.
Comment #3
Gábor HojtsyComment #5
hass CreditAttribution: hass commentedPlacing a boolean in quotes looks wrong to me. We have boolean type for variables in .yml files.
Comment #6
Gábor Hojtsysystem.routing.yml and other routing files are full of
It is true that some things use TRUE (without quotes) even in system.routing.yml, there is no real consistency. It does not actually matter from the code if its a string or a bool, if its 'TRUE' or TRUE, it evaluates to true either way.
Comment #7
hass CreditAttribution: hass commentedI was not aware of this. I only remembered when I defined types in schema files of my modules I started to run into issues when I tried to save a wrong type.
Comment #8
Gábor Hojtsy@hass: config files saved using config schema will enforce types, routing.yml are developer written and does not enforce types for values programatically.
Comment #9
hass CreditAttribution: hass commentedThat is very inconsistent. DX fail.
Comment #10
hass CreditAttribution: hass commentedCreated followup #2406397: Change all values in yml files to correct data type
Comment #11
jhodgdonPatch looks good to me.
We will need to have a change record and beta evaluation.
Also, adding link to original issue where this parameter was added. As a note there was no change record there.
Comment #12
olli CreditAttribution: olli commented#2137595: 'Create @name' page title uses override-free configuration (eg. not localized) instead of the overridden configuration (eg. localized) landed.
Comment #13
Gábor HojtsyAdded change notice at https://www.drupal.org/node/2407035 (draft), added beta evaluation to issue summary. @jhodgdon: what do you think? :)
Comment #14
jhodgdonLooks good, thakns! I think the change notice should mention the previous name of the parameter, so I added a short note. This would allow someone whose contrib module using the old option suddenly broke to search and find this change notice.
Comment #15
Gábor Hojtsy@jhodgdon: thanks. Looks like all this needs is a review confident to RTBC :)
Comment #16
jhodgdonI have verified that this patch changes all current Core uses of 'use_current_language' to 'with_overrides'. I think the new parameter name is clearer than the old. Tests pass. There's a beta evaluation and a change notice.
Let's do it!
Comment #17
Gábor HojtsyAssigning to @alexpott as #2392319: Config objects (but not config entities) should by default be immutable might necessitate changing the terminology here.
Comment #18
alexpottLet's go with
with_config_overrides
. I don't think aligning to thegetEditable()
terminology from #2392319: Config objects (but not config entities) should by default be immutable is relevant - since entities (including config entities) are mutable.Comment #19
Gábor HojtsyRolled with that name. Updated issue summary and change notice.
Comment #20
DevElCuy CreditAttribution: DevElCuy commentedComment #21
DevElCuy CreditAttribution: DevElCuy commentedRemoved SprintWeekend2015Queue by mistake.
Comment #22
alexpottYep
use_current_language
is a bad name when this relates to config overrides. Committed cc9d0f9 and pushed to 8.0.x. Thanks!Comment #24
Gábor Hojtsy