Problem/Motivation
If you have a look at https://api.drupal.org/api/drupal/core%21modules%21system%21templates%21... it points to
@see template_preprocess_status_messages()
this function though no longer exists, yeah, the logic for that moved entirely into the template, see core/themes/classy/templates/misc/status-messages.html.twig
Proposed resolution
Clean up as many of those templates to no longer point to non existing functions.
Here's a grep to get a list of all:
grep -ihREo --include="*.twig" '(\w*)\(\)' core | sort | uniq
And to get the file names they are in:
grep -iREo --include="*.twig" '(\w*)\(\)' core | sort
Remaining tasks
User interface changes
API changes
Data model changes
Comment | File | Size | Author |
---|---|---|---|
#17 | remove_references_to-2587685-17.patch | 14.03 KB | AjitS |
#8 | interdiff.txt | 1.12 KB | Antti J. Salminen |
#8 | remove_references_to-2587685-8.patch | 14.43 KB | Antti J. Salminen |
| |||
#7 | interdiff.txt | 6.7 KB | lauriii |
#7 | remove_references_to-2587685-7.patch | 13.31 KB | lauriii |
|
Comments
Comment #2
Sagar Ramgade CreditAttribution: Sagar Ramgade as a volunteer commentedThe patch attached removes all the references to template_preprocess_status_messages().
Comment #3
rang501 CreditAttribution: rang501 at ADM Interactive commentedRemoves the following references:
template_preprocess_config_translation_manage_form_element
template_preprocess_dropbutton_wrapper
template_preprocess_menu_local_tasks
template_preprocess_page_title
template_preprocess_tablesort_indicator
template_preprocess_update_version
template_preprocess_views_ui_container
Patch is attached. I think there's no references left in template files.
Comment #4
joelpittetThis is pretty good I did notice bartik is referencing bartik_preprocess_page() which doesn't exist. Could you do a search through all @see's in twig templates to see the functions exist?
Here's a grep to get a list of all:
grep -ihREo --include="*.twig" '(\w*)\(\)' core | sort | uniq
And to get the file names they are in:
grep -iREo --include="*.twig" '(\w*)\(\)' core | sort
Comment #5
jaakko CreditAttribution: jaakko as a volunteer commentedComment #6
jaakko CreditAttribution: jaakko as a volunteer commentedRemoving following references:
template_preprocess_page_title()
template_preprocess_views_ui_container()
template_preprocess_update_version()
bartik_preprocess_page()
bartik_preprocess_field()
template_preprocess_views_ui_container()
template_preprocess_update_version()
Comment #7
lauriiiComment #8
Antti J. Salminen CreditAttribution: Antti J. Salminen as a volunteer commentedFound two additions. I think this should be all of them, I compared lists of undefined ones with the ones in the patch and only came up with these. Looks good to me otherwise.
Comment #9
joelpittetNice hunting
Comment #11
joelpittetBack to black
Comment #15
joelpittetThe bartik patch seems to conflict with #2613998: Remove bartik_preprocess_page() reference from page.html.twig
Comment #16
AjitSWorking on it now.
Comment #17
AjitSRerolled.
Comment #18
joelpittetPerfect, I diffed the diffs and the re-roll looks great.
Comment #23
catchCommitted/pushed to 8.1.x and cherry-picked to 8.0.x. Thanks!
Comment #25
iMiksuCleaning up drupalcampfi tags.