Repository navigation
Version 5.1.1: ignore Redis errors when releasing a mutex lock handle - #82
Merged
Merged
Conversation
Disposing the handle rejected when the compare-and-delete failed, so an await using block threw after its work succeeded, or wrapped its own error in a SuppressedError. Ignore the error like the semaphore functions do; the lock expires via its TTL. Version 5.1.1. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Coverage Report for CI Build 40391363468Coverage remained the same at 100.0%Details
Uncovered ChangesNo uncovered changes found. Coverage RegressionsNo coverage regressions found. Coverage Stats
💛 - Coveralls |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
[Symbol.asyncDispose]now ignores errors from the compare-and-delete, the same way the semaphore functions ignore unlock errors. The lock expires via its TTL.disableOfflineQueue: true) made theawait usingblock throw after its work succeeded. In catalog-service's Service Bus handlers, that redelivers a message that was already handled. If the block also threw, the block's error came out wrapped in aSuppressedError.Tests
PettyCache.mutex.lock handle should ignore Redis EVAL errors: with EVAL stubbed to reject, the release resolves, and anawait usingblock that throws rejects with its ownError, not aSuppressedError. This test fails against 5.1.0'sindex.js.🤖 Generated with Claude Code