-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
forge script --ledger
deployment fails
#2709
Comments
@joshieDo i think we've seen this before? Was it because maybe smart contract interactions are not set to TRUE in the Ledger? |
forge script
: deployment with ledger fails
forge script
: deployment with ledger failsforge script --ledger
deployment fails
I didn't even know that being a thing. @dekz Can you confirm? Sometimes this error occurs when another process takes ownership of the device and doesn't let go. But given |
Not sure what this option is, are you refering to blind signing? In which case this is enabled, and My script is essentially a contract I'll try simpler and simpler scripts to see if anything is successful. |
I don't have a ledger with me at the moment, in a few days I can try it out as well. What version is your ledger on? |
|
Just trying a basic test, deploying a simple contract.
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.6.5;
contract MyContract {
function getBlockNumber()
public
view
returns (uint256)
{
return block.number;
}
}
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.6.5;
import "forge-std/Script.sol";
import "forge-std/Test.sol";
import "./MyContract.sol";
contract DScript is Script, Test {
function run() public {
emit log_named_address("msg.sender", msg.sender);
vm.startBroadcast();
MyContract myContract = new MyContract();
vm.stopBroadcast();
emit log_named_uint("blockNumber", myContract.getBlockNumber());
}
}
|
finally got a hold of my ledger and was able to reproduce it. sorry it took so long, issue linked |
Thanks legends, I'll try it shortly and get back to you if there are any other issues. |
Confirmed working and I was able to use both thanks again @joshieDo . |
Component
Forge
Have you ensured that all of these are up to date?
What version of Foundry are you on?
forge 0.2.0 (6cd6618 2022-08-11T00:05:44.416299Z)
What command(s) is the bug in?
forge script --ledger
Operating System
macOS (Apple Silicon)
Describe the bug
I can successfully use
cast send --ledger
but am unable to useforge script --ledger
with error of:Can confirm that cast send works exactly as expected, so could be my misuse of
forge script
.I'm using the following command
I can confirm that
0xABCD
is at the hd-pathm/44'/60'/0'/1
Immediately switching over to
cast send
and there is no issue at all.Successfully sends a transaction to itself from itself using the ledger
The text was updated successfully, but these errors were encountered: