The exception 502 Bad Gateway is quite a common exception after we have moved the cloud infrastructure to the AWS. The error is probably due to the Load balancer being unreachable or busy. In such cases, it is a good idea to retry the request. The code retries the request thrice before returning a response or an exception.
New dependencies: (Added to requirements_dev.txt)
pytest_localserver
Fixes #167
Type of Change
[ ] Bug fix (non-breaking change which fixes an issue -> bump patch)
[x] New feature (non-breaking change which adds functionality -> bump minor version)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected -> bump major version)
[ ] Documentation Update
[ ] CI/CD workflows Update
Checklist
[x] I have added tests that prove that my fix/feature works
[ ] Linters pass locally and I have followed PEP8 code style
[x] New and existing tests pass locally
[ ] I have updated the documentation if needed
[x] I have commented hard-to-understand areas in the code
Description
The exception
502 Bad Gateway
is quite a common exception after we have moved the cloud infrastructure to the AWS. The error is probably due to the Load balancer being unreachable or busy. In such cases, it is a good idea to retry the request. The code retries the request thrice before returning a response or an exception.New dependencies: (Added to requirements_dev.txt)
pytest_localserver
Fixes #167
Type of Change
Checklist
Requirements