Viewers & edit collaborators on a project can't see the list of collaborators

Aperta
#534 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
67/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
python
Ambito
backend

Direzione di ricerca

Start with the collaboration view in documentcloud/projects/views.py around line 675, then read the permission definitions in documentcloud/projects/rules.py around lines 47 and 53. Trace how the project collaborator list is gated and identify a collaborator-level check for viewing it while keeping the existing permission for settings and invitations. Done means viewers and editors can see the collaborator list, while the existing admin-only actions remain gated.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

bug
Image

If projects are intended to be a collaborative space, this is a confusing user experience. If someone adds me to a project as a viewer or editor, I have no idea who added me at this point.

The collaboration view set is gated by an if here:
https://github.com/MuckRock/documentcloud/blob/d5f6a31764fafd315603503c6c75dc5b4e1c6726/documentcloud/projects/views.py#L675
projects.change_project_all is the permission which gates it.

This is defined here:
https://github.com/MuckRock/documentcloud/blob/d5f6a31764fafd315603503c6c75dc5b4e1c6726/documentcloud/projects/rules.py#L53
as anyone who holds can_change

which is defined here:
https://github.com/MuckRock/documentcloud/blob/d5f6a31764fafd315603503c6c75dc5b4e1c6726/documentcloud/projects/rules.py#L47

That means only authenticated admins of the project can see the collaborator list.

So the collaborators list is tied to the same permission as editing project settings and inviting people. That’s why only admins see it. The fix is to give the list its own collaborator-level check, and leave this permission as is I think.

Lingua principale
Python
Stelle
55
Fork
10
Merge medio
1g 13h
PR unite (30g)
22

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di MuckRock/documentcloud

Tutte le issue di MuckRock/documentcloud

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.