feat: add screenshot retry logic for transient browser failures
Some checks failed
Build & Deploy to Staging / Build & Deploy to Staging (push) Has been cancelled
Some checks failed
Build & Deploy to Staging / Build & Deploy to Staging (push) Has been cancelled
- Add isRetryableError() helper (retry on TimeoutError, Protocol error, Target closed, Session closed, Navigation failed, net::ERR_*) - Wrap browser screenshot in retry loop (max 2 retries, exponential backoff) - Add retryCount to ScreenshotResult, X-Retry-Count response header - Validation/SSRF/auth errors are NOT retried - 28 new tests (12 retry classification + 6 screenshot retry + route tests)
This commit is contained in:
parent
8a36826e35
commit
fde5aea324
6 changed files with 184 additions and 8 deletions
4
package-lock.json
generated
4
package-lock.json
generated
|
|
@ -1,12 +1,12 @@
|
|||
{
|
||||
"name": "snapapi",
|
||||
"version": "0.7.0",
|
||||
"version": "0.8.0",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "snapapi",
|
||||
"version": "0.7.0",
|
||||
"version": "0.8.0",
|
||||
"dependencies": {
|
||||
"compression": "^1.8.1",
|
||||
"express": "^4.21.0",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue