Follow-up from #1912602: Changing view access from "Permission" to "Role" causes AJAX error message re getRoles().
Problem/Motivation
As mentioned in [#8277631-39] by @catch
+++ b/core/modules/views/lib/Drupal/views/Plugin/views/display/PathPluginBase.php
@@ -185,6 +185,10 @@ protected function getRoute($view_id, $display_id) {
+ $route->setOption('_access_mode', 'ANY');
This looks like it could easily end up as an information disclosure vulnerability down the line, so I'm not really comfortable doing it in a follow-up - or at least that follow-up also needs to be critical.
Proposed resolution
Need to find one.
Remaining tasks
1. Discuss
2. Issue patch
User interface changes
N/A
API changes
N/A