Page MenuHomePhabricator

Badly limiting a dashboard widget's "Can View" policy can result in users not being able to see a dashboard
Closed, DuplicatePublic

Description

What I tried to do: As an admin of a quite small Phabricator instance, I wanted to put a widget for our new, non-dev users to see recent tasks from the project they're working on in Phabricator to make the learning curve a little less steep. As I can't use Spaces to install a dashboard for particular users (I can only install a dashboard for myself or for everybody), I installed it for everybody and set their little widget's view policy to "Members of Project X", not wanting other users to have an empty widget on their home screen. As I'm a member of that project, I didn't realise what happens when you do that until another admin tried to use Phabricator and sent me the following screenshot.

What it resulted in:

All other users were greeted by this beauty:

IMG_2016-12-11 18:24:42.jpg (716×1 px, 40 KB)

While I do realise this is mostly my fault, I really don't think this is expected behaviour as there's no point in having a Can View policy on widgets if changing it results in the dashboard crashing miserably.

Reproduction steps

  1. Create a project and add yourself as a member
  2. Create a Maniphest search widget on a dashboard and set the Can View policy to the project members.
  3. Install the dashboard for all users
  4. Log in using a user account that's not a project member
  5. You get an error instead of a dashboard.

Version info

phabricator
    74a0e5cd7930ac06013ed6fafc4fd96e7730b40c (Sat, Nov 19) 
arcanist
    e17fe43ca3fe6dc6dd0b5ce056f56310ea1d3d51 (Oct 22 2016) 
phutil
    b4f866bd75ec138397a16337bc5d326e586a6276 (Sat, Nov 19)

Not the latest, but the changelogs don't say anything about dashboard widgets. I can update if it's necessary.

Event Timeline

This is expected behavior. We want to show an error instead of just vanishing the widget.

Okay then, I thought this was a bug as it didn't seem to make sense for me as a user. Sorry for taking up your time.

We have an identical ticket we plan to fix, definitely agree it's a bad experience.