Closed rhamzeh closed 7 months ago
The SDK currently retries only on 429 errors
https://github.com/openfga/python-sdk/blob/main/openfga_sdk/sync/api_client.py#L210-L234
It should retry on 429 and 5xx errors except for 501 Not Implemented
SDK retries on 5xx errors
v0.4.1
N/A
configuration = ClientConfiguration( api_url=FGA_API_URL, # required store_id=FGA_STORE_ID, # optional, not needed when calling CreateStore or ListStores authorization_model_id=FGA_AUTHORIZATION_MODEL_ID, # Optional, can be overridden per request credentials=Credentials( method='client_credentials', configuration=CredentialConfiguration( api_issuer=FGA_API_TOKEN_ISSUER, api_audience=FGA_API_AUDIENCE, client_id=FGA_CLIENT_ID, client_secret=FGA_CLIENT_SECRET, ) ) )
CreateStore
ListStores
No response
Checklist
Description
The SDK currently retries only on 429 errors
https://github.com/openfga/python-sdk/blob/main/openfga_sdk/sync/api_client.py#L210-L234
It should retry on 429 and 5xx errors except for 501 Not Implemented
Expectation
SDK retries on 5xx errors
Reproduction
OpenFGA SDK version
v0.4.1
OpenFGA version
N/A
SDK Configuration
configuration = ClientConfiguration( api_url=FGA_API_URL, # required store_id=FGA_STORE_ID, # optional, not needed when calling
CreateStore
orListStores
authorization_model_id=FGA_AUTHORIZATION_MODEL_ID, # Optional, can be overridden per request credentials=Credentials( method='client_credentials', configuration=CredentialConfiguration( api_issuer=FGA_API_TOKEN_ISSUER, api_audience=FGA_API_AUDIENCE, client_id=FGA_CLIENT_ID, client_secret=FGA_CLIENT_SECRET, ) ) )Logs
No response
References
No response