Open martriay opened 2 years ago
I am applying to this issue via OnlyDust platform.
I have experience in all the languages used in the issue, so it would be easier for me to achieve it.I also want to make my first issue
To improve the pollVerificationStatus function, consider replacing the blocking while loop with an asynchronous approach using await and setTimeout to reduce CPU usage and prevent tight looping. Enhance error handling by checking for error.response to avoid potential undefined errors, and improve the error logging to provide more context. Additionally, make the retryInterval a configurable parameter to allow for greater flexibility in how often retries occur, accommodating different network conditions or requirements. These changes will make the function more efficient, flexible, and robust.
https://github.com/NethermindEth/voyager-verify/blob/main/lib/requests.ts