I am uploading this PR to propose a solution for issue #5046. The current implementation simply reverts with a generic FailedDeployment error, which obscures potentially useful debugging information contained in the returndata.
So in the changes, deploy function was enhanced in the following way:
returndata is captured when a create2 deployment fails.
If returndata is available, it is used to revert, providing the original error message from the failed deployment.
If no returndata is available, the function reverts with the existing generic FailedDeployment error.
The changes were tested locally, and the expected output was given.
Fixes #5046
I am uploading this PR to propose a solution for issue #5046. The current implementation simply reverts with a generic FailedDeployment error, which obscures potentially useful debugging information contained in the returndata. So in the changes, deploy function was enhanced in the following way:
The changes were tested locally, and the expected output was given.
npx changeset add
)