Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Deleting a resource leaves the policies granted on it

Aperta
#1,993 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
62/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
go

Direzione di ricerca

Start with Delete and Purge in core/resource/service.go, which remove the resource's relations and row but never touch the policy service. Reproduce the steps with CreatePolicy, DeleteProjectResource, then ListPolicies and GetPolicy, and check the policy rows and role binding relations that remain. Done means that deleting a resource, directly or through the project delete cascade, also removes its policies, and ListPolicies no longer returns them.

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

Descrizione

Deleting a resource removes its SpiceDB relations and soft-deletes its row. Policies granted on the resource are not deleted. Their rows and their two role binding relations stay, and ListPolicies still returns them. They no longer grant anything, because the link from the resource to the role binding is gone.

The project delete cascade purges project resources the same way, so policies on them stay too.

Steps

  1. Create a resource and grant a user a role on it with CreatePolicy.
  2. Delete the resource with DeleteProjectResource.
  3. ListPolicies for the user still returns the policy, and GetPolicy still finds it.

Code
Delete and Purge in core/resource/service.go delete the resource's relations and row, but never call the policy service.

Expected
Deleting a resource also deletes the policies on it.

Lingua principale
Go
Stelle
343
Fork
48
Merge medio
2g 9h
PR unite (30g)
48

Preparare l'ambiente

  • Include un Dockerfile o un file Docker Compose
  • Ha un modello di pull request
  • Nessuna guida per i contributori

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 raystack/frontier

Tutte le issue di raystack/frontier

Issue simili

Altre issue su Go

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.