You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Whenever an RPC request encounters an error, it results in an uncaught rejection. This means that even if the outer call is wrapped in a try-catch block, the error cannot be caught and handled properly.
Steps to reproduce
Make an RPC request using the solana-web3.js library.
Force an error condition for the request.
Wrap the request call in a try-catch block.
Observe that the error is not caught by the try-catch block and results in an uncaught rejection.
Description of bug
There is an issue in the packages/library-legacy/src/connection.ts file at line 1679. Whenever an RPC request encounters an error, it results in an uncaught rejection. This means that even if the outer call is wrapped in a try-catch block, the error cannot be caught and handled properly.
Expected Behavior:
The error should be caught and handled properly within the try-catch block surrounding the RPC request call.
Actual Behavior:
The error results in an uncaught rejection, bypassing the try-catch block.
Proposed Solution:
Add a try-catch block around the RPC request in packages/library-legacy/src/connection.ts at line 1679 to handle errors properly and prevent uncaught rejections.
The text was updated successfully, but these errors were encountered:
Overview
Whenever an RPC request encounters an error, it results in an uncaught rejection. This means that even if the outer call is wrapped in a try-catch block, the error cannot be caught and handled properly.
Steps to reproduce
Description of bug
There is an issue in the packages/library-legacy/src/connection.ts file at line 1679. Whenever an RPC request encounters an error, it results in an uncaught rejection. This means that even if the outer call is wrapped in a try-catch block, the error cannot be caught and handled properly.
Expected Behavior:
The error should be caught and handled properly within the try-catch block surrounding the RPC request call.
Actual Behavior:
The error results in an uncaught rejection, bypassing the try-catch block.
Proposed Solution:
Add a try-catch block around the RPC request in packages/library-legacy/src/connection.ts at line 1679 to handle errors properly and prevent uncaught rejections.
The text was updated successfully, but these errors were encountered: