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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You added transactionId to the getStatus call but the module-level cache TRANSACTION_HASH_OBSERVERS is still keyed only by txHash. This can cause cached responses to be reused across requests with different transactionId values. Consider including transactionId in the cache key or avoid module-level per-request caching.
Details
✨ AI Reasoning
A module-level cache (TRANSACTION_HASH_OBSERVERS) stores promises keyed by txHash. The PR adds transactionId into the request payload, so two requests with the same txHash but different transactionId will still reuse the same cached promise. This can leak or mix request-specific data between callers and cause incorrect status results. The problem was introduced/worsened by adding transactionId to the request without changing caching behavior.
🔧 How do I fix it?
Avoid storing request-specific data in module-level variables. Use request-scoped variables or explicitly mark shared caches as intentional.
Reply
@AikidoSec feedback: [FEEDBACK]to get better review comments in the future.Reply
@AikidoSec ignore: [REASON]to ignore this issue.More info