Checklist
Description
The docs describe how to use the read() method with a TupleKey with no relation set to get a list of all relations a user has with an object. Currently the TupleKey object validation prevents the relation from being None.
Expectation
Not to throw an error when omitting relation or setting to None.
Reproduction
Essentially the code from the docs:
body = TupleKey(
user="user:bob",
object="document:123",
)
Working around the validation and submitting the query confirms the behavior describes from the docs (i.e., listing the relations) works as expected:
Issuing a query with a workaround:
body = TupleKey(
user="user:bob",
relation="",
object="document:123",
)
body._relation = None
# call `read(body)` ...
OpenFGA SDK version
0.4.0 (but the code in main appears broken)
OpenFGA version
v1.5.0
SDK Configuration
[default options]
Logs
No response
References
No response
Checklist
Description
The docs describe how to use the
read()method with aTupleKeywith norelationset to get a list of all relations a user has with an object. Currently theTupleKeyobject validation prevents therelationfrom beingNone.Expectation
Not to throw an error when omitting
relationor setting toNone.Reproduction
Essentially the code from the docs:
Working around the validation and submitting the query confirms the behavior describes from the docs (i.e., listing the relations) works as expected:
Issuing a query with a workaround:
OpenFGA SDK version
0.4.0 (but the code in main appears broken)
OpenFGA version
v1.5.0
SDK Configuration
[default options]
Logs
No response
References
No response