Closed tadejsv closed 1 year ago
@tadejsv This is by design: The bulk check permissions has a streaming response and will returns results as they are computed; this is why each returned result contains a pair
that includes the initial request: to ensure it can be correlated with the request that created the response
But it doesn't actually have a streaming response?
I guess that was changed at some point... we can look into reordering the response then, although the intent is still to use the request information from the pairs for correlation, not the order
+1 to ordered results. It makes the APIs really ergonomic from the client's perspective.
# pseudocode
resources = resources_to_check = [...]
responses = spiceDB.bulk_check(resources)
authorized_resources = [
resource
for resource, response in zip(resources, responses)
if response # filter down to access granted
]
What platforms are affected?
linux, macos, windows
What architectures are affected?
amd64, arm64
Steps to Reproduce
I have noticed that in some cases,
BulkCheckPermission
returns the results (permissions) in a different order than requests.Expected Result
I think the desired behavior would be to return results in the same order as requests
Actual Result
-