Skip to content

zed backup redact fails when schema contains .any() or .all() #716

Description

@corkrean

zed backup redact fails for the following schemas:

 definition user {}

  definition document {
        relation viewer: user
        relation upstream: document
        permission read = viewer + upstream.any(read)
  }
definition user {}

  definition document {
        relation viewer: user
        relation upstream: document
        permission read = viewer + upstream.all(read)
  }

The error is as follows:
9:31AM ERR terminated with errors error="error creating redactor: BUG: *errors.errorString unknown child type: *corev1.SetOperation_Child_FunctionedTupleToUserset\n/Users/runner/go/pkg/mod/github.com/authzed/spicedb@v1.53.1-0.20260612201921-1d5d2c81ab70/pkg/spiceerrors/bug.go:36 (0x1018ac134)\npkg/backupformat/redaction.go:297 (0x101ddc1a0)\npkg/backupformat/redaction.go:261 (0x101ddbf04)\npkg/backupformat/redaction.go:244 (0x101ddb604)\npkg/backupformat/redaction.go:81 (0x101ddb004)\ninternal/cmd/backup.go:600 (0x102a55a88)\n/Users/runner/go/pkg/mod/github.com/spf13/cobra@v1.10.2/command.go:1015 (0x1011a3b24)\n/Users/runner/go/pkg/mod/github.com/spf13/cobra@v1.10.2/command.go:1148 (0x1011a4280)\n/Users/runner/go/pkg/mod/github.com/spf13/cobra@v1.10.2/command.go:1071 (0x102a5a6f0)\n/Users/runner/go/pkg/mod/github.com/spf13/cobra@v1.10.2/command.go:1064 (0x102a5a6e9)\ninternal/cmd/cmd.go:164 (0x102a5a6f1)\ninternal/cmd/cmd.go:136 (0x102a5a4fc)\ncmd/zed/main.go:6 (0x102a6504c)\n$GOROOT/src/internal/runtime/atomic/types.go:194 (0x100fd3854)\n$GOROOT/src/runtime/asm_arm64.s:1447 (0x101011b44)\n"

zed backup redact does not encounter an error when the arrow operator -> is used.

zed backup does not encounter issues with the .any() and .all() operator

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions