Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 291720

Render caching in DisplayPluginInterface::buildRenderable is broken when arguments are provided.

$
0
0

Problem/Motivation

Right now the only part of views which adds arguments to views cache keys is "DisplayPluginBase::buildBasicRenderable".

My specific use case involved programmatically rendering a block with different arguments. 'url' was the only cache context that appeared and given two of these blocks were programatically rendered on the same page, the markup was the same regardless of the arguments. Using the static method fixed this.

Proposed resolution

Views should add these to all displays, not making developers rely on the static to add this for them. I can't see a downside with making the views arguments part of the cache keys for all scenarios.

Remaining tasks

User interface changes

API changes

Data model changes


Viewing all articles
Browse latest Browse all 291720

Trending Articles