Problem/Motivation

ViewsSourceBase keeps one view per view and display for the whole request. But a view entity always gives back the same view object. So when two components get the same view entity with two different displays, both show the results of the first display.

When the view or the display does not exist, no cache tags are added. The empty output then stays in cache after the view is fixed.

The view is also read from the Views UI temporary storage for every user, and view access is never checked.

This only happens when a module passes the view entity without the running view.

Proposed resolution

We could:
- key the stored views on the view object instead of the view entity,
- add the view's cache tags even when the view or display is missing,
- read the Views UI temporary storage only for users who can edit views, and check view access.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

just_like_good_vibes created an issue. See original summary.

just_like_good_vibes’s picture

Assigned: just_like_good_vibes » Unassigned
Status: Active » Fixed

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.