Skip to content

fix: Remove retried item from the queue during reset #2044

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

dermasmid
Copy link
Contributor

we are seeing accessional uncaught errors like such:

TypeError: Cannot read properties of undefined (reading 'nextRetry')
    at Heap.comparator [as compare] (/usr/src/app/node_modules/@tw/pubsub/build/src/exponential-retry.js:21:24)
    at Heap._sortNodeDown (/usr/src/app/node_modules/heap-js/dist/heap-js.umd.js:2148:43)
    at Heap.replace (/usr/src/app/node_modules/heap-js/dist/heap-js.umd.js:1987:18)
    at Heap.pop (/usr/src/app/node_modules/heap-js/dist/heap-js.umd.js:1902:29)
    at ExponentialRetry.doRetries (/usr/src/app/node_modules/@tw/pubsub/build/src/exponential-retry.js:117:29)
    at Timeout._onTimeout (/usr/src/app/node_modules/@tw/pubsub/build/src/exponential-retry.js:142:22)
    at listOnTimeout (node:internal/timers:573:17)
    at process.processTimers (node:internal/timers:514:7)

this is an attempt at solving it.

@dermasmid dermasmid requested review from a team as code owners May 17, 2025 21:54
@product-auto-label product-auto-label bot added size: xs Pull request size is extra small. api: pubsub Issues related to the googleapis/nodejs-pubsub API. labels May 17, 2025
@dermasmid
Copy link
Contributor Author

this has now been tested, and did fix the issue for us

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: pubsub Issues related to the googleapis/nodejs-pubsub API. size: xs Pull request size is extra small.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant