Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
As a follow up of #1869566: Allow any collection of plugins to be lazily instantiated let's use the real methods and don't rely on the magic functions anymore.
Comment | File | Size | Author |
---|---|---|---|
#36 | vdc-1876942-36.patch | 102.72 KB | tim.plunkett |
#33 | interdiff.txt | 373 bytes | dawehner |
#32 | drupal-1876942-32.patch | 102.69 KB | damiankloip |
#30 | drupal-1876942-29.patch | 103.23 KB | dawehner |
#30 | interdiff.txt | 3.29 KB | dawehner |
Comments
Comment #1
dawehnerHere is a first patch, which is for sure not testable yet.
Comment #2
damiankloip CreditAttribution: damiankloip commentedRerolled.
Comment #3
tim.plunkettTo make sure we got them all, you can remove the ArrayAccess parts from PluginBag and see what blows up :)
Comment #5
damiankloip CreditAttribution: damiankloip commentedYeah, why not. This patch should actually work. Also attached one with the ArrayAccess methods removed from PluginBag.
Comment #7
dawehnerSome serious bug fix ;)
Comment #8
dawehnerWrong patch
Comment #10
damiankloip CreditAttribution: damiankloip commentedWe could do this? Although I don't think it's a great idea. This should work, but we have to initDisplay(). This should show that ht erest of your patch works atleast.
I would sooner wait for #1867304: Assess newDisplay method on ViewExecutable to get in, then I think the current patch will be ok.
Comment #11
damiankloip CreditAttribution: damiankloip commentedOops
Comment #13
dawehnerYeah let's wait and then fix the remaining ones.
Comment #14
damiankloip CreditAttribution: damiankloip commentedOk, rerolled. I ran some of the previously failing tests and they pass. So I think this patch might be good now.
Comment #16
damiankloip CreditAttribution: damiankloip commentedThat last patch was all messed up, it was chnaging back changes made from recent commits! Not sure how or why it got so messed up Let's try this.
I also changed the get method on the PluginBag to return by reference. Review carefully :)
Comment #18
damiankloip CreditAttribution: damiankloip commentedAnd maybe now this; destroy() is unsetting displayHandlers, so we can't use has() to check displays. So I've Just changed the assertions to match the others...
Comment #19
tim.plunkettWe're losing one assertion here, any particular reason? In fact, this whole hunk doesn't look related to the issue.
These look like stray changes.
---
Can we also lump in the ArrayAccess removal from PluginBag again? We might as well kill it before others try to use it, and we can be sure we've 100% converted everything.
Comment #20
damiankloip CreditAttribution: damiankloip commentedGood points, If no one else does first, I will look at this in about an hour. I knew there was some crazy stuff going on with the changes, indeed unrelated, that's why I said review carefully :) Good job.
Comment #21
damiankloip CreditAttribution: damiankloip commentedMade those changes. Sorry I've just realised I forgot an interdiff, how rude.
Comment #22
tim.plunkettAs a punishment for forgetting an interdiff, you have to reroll!
You missed removing
implements \ArrayAccess
from the class definition, as well as the comment above it.Comment #23
damiankloip CreditAttribution: damiankloip commentedAhahaha, fair IS fair. Here you go.
Comment #25
tim.plunkettAh, we just missed one direct call to offsetGet() that should never have existed.
I've reviewed the entire patch several times, and this is done.
Comment #27
dawehnerMh, I seemed to have missed some of the places.
Don't take patches to serious at 5 am, but at least this fixes hopefully the tests :)
Comment #29
tim.plunkettIn PluginBagTest::testPluginBag()
Delete the first one, and s/exits/exists/ on the second
Not sure about the other failure
Comment #30
dawehnerHey, we also have to clean up some tests :)
Comment #32
damiankloip CreditAttribution: damiankloip commentedSorry, I think is still from the messed up diff I provided earlier in the issue. This should be good now.
Comment #33
dawehnerJust for other people :) This has been part of another patch.
Comment #34
catch#32: drupal-1876942-32.patch queued for re-testing.
Comment #36
tim.plunkettJust a patch context conflict with #1821524: Decouple use of default views in ViewStorageTest, no changes.
Comment #37
catchCommitted/pushed to 8.x, thanks!
Comment #38
damiankloip CreditAttribution: damiankloip commentedSuper.