Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

Deleting a resource leaves the policies granted on it

Abierto
#1,993 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
62/100
Tipo de issue
Error
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
go

Línea de trabajo

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.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

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.

Lenguaje dominante
Go
Estrellas
344
Forks
48
Merge medio
2 d 9 h
PR fusionados (30 d)
47

Preparar el entorno

  • Incluye un Dockerfile o un archivo de Docker Compose
  • Tiene una plantilla de pull request
  • Sin guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de raystack/frontier

Todos los issues de raystack/frontier

Issues similares

Más issues de Go

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.