Closed (fixed)
Project:
Drupal core
Version:
10.3.x-dev
Component:
filter.module
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
16 Feb 2024 at 09:03 UTC
Updated:
20 Apr 2024 at 16:59 UTC
Jump to comment: Most recent
Comments
Comment #3
scott_euser commentedTests showing this is failing with:
Results in:
Note that when you have twig debug enabled, line breaks are always added before and after the nested twig template, even with
{% apply spaceless %}{% end apply %}Comment #4
scott_euser commentedOkay this handles it now. Avoided regex here as its getting overly complicated given the regex would need to work across lines. Figured it is more straightforward and readable to check subsequent and preceding lines.
To test this out, without change to filter.module, this now fails:
With the change to filter.module, it passes.
Comment #5
scott_euser commentedComment #6
wim leersComment #7
wim leersMakes sense!
Note that only the text format uses this by default. If you're using CKEditor 5, you should not be using
filter_autopat all, and you can safely disable it.Comment #8
wim leersThanks for doing this! :)
Comment #9
scott_euser commentedThanks for the quick review! Applied your suggestions, looks like this is ready to go then. Thanks!
Comment #10
scott_euser commentedUpdating issue summary to mark all as completed as well (forgot!)
Comment #11
nod_Needs updating after #3420709: Make it more obvious that a Twig template is overridden got in
Comment #12
scott_euser commentedThanks for flagging. I updated the filter to cover that now + added an additional bit to the test.
Comment #13
smustgrave commentedCan the MR be rebased please
Comment #14
scott_euser commentedI think I did grab all from 11.x and merge it in. Isn't the squashing of commits happening when this eventually gets merged in? Probably I am not understanding what you are asking @smustgrave sorry :)
Comment #15
smustgrave commentedAppears to be failing unit tests but have seen that resolved with a rebase.
Comment #16
scott_euser commentedAh I see, thanks!
Comment #17
smustgrave commentedSeeing green now
Ran the test-only feature https://git.drupalcode.org/issue/drupal-3421843/-/jobs/995505 and it failed as expected.
Appears feedback has been addressed with regards to #11.
Looks good!
Comment #18
scott_euser commentedAh nice, handy feature; saw that 'Downstream failure' and got curious. Thanks for jumping in and helping get this one ready again!
Comment #19
catchOne question on the MR.
Comment #20
scott_euser commented@catch added a suggested route instead of making it more generic - what do you think?
Comment #21
smustgrave commented@scott_euser seemed to got the thumbs up for that approach
Comment #22
scott_euser commentedComment #23
smustgrave commentedDid a rebase and that unit failure went away. Seen that on a few slightly older tickets.
From what I can tell feedback has been addressed and the update didn't break the changes added in #3420709: Make it more obvious that a Twig template is overridden
Comment #28
nod_Committed 6ac4200 and pushed to 11.x. Thanks!
Comment #30
nod_Tests fail on 10.2.x, won't backport there. Please open a 10.2.x MR for it if it's important to have on that version.
Comment #31
scott_euser commentedGreat thank you both!