-
Notifications
You must be signed in to change notification settings - Fork 175
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
Preflight error [account Address already in use] [mainnet only] #46
Comments
I was encountering the same exact issue. Have you found a workaround yet? Seems this repo isn't actively managed. |
Encountering the very same issue, no workaround found yet, the comments in lines 227+ of https://docs.rs/solana-program/latest/src/solana_program/pubkey.rs.html#195-205 are an interesting read. |
Hey everyone - we're looking into this and will update this thread shortly. Thank you. |
@0xLOLK @l1quid8 @DaniMeier I believe the issues you're facing are due to the fact the account you're attempting to initiate already exists. You need to generate random seeds for the PDA of the program that will hold the vesting info. An example is here: vesting example. |
I'll be closing this issue now. Please feel free to reopen another one if this persists. |
I am still encountering this issue, even with a newly generated seed |
@l1quid8 Please share as much detail as you can regarding the error you're seeing, and method you're using to generate the new seed. I'll take this back to my team. |
I am using `RUST_BACKTRACE=1 ./target/debug/vesting-contract-cli --url https://api.mainnet-beta.solana.com --program_id CChTq6PthWU82YZkbveA3WDf7s97BWhBK4Vx9bmsT743 create --mint_address EU3zHrJnEEzhPHbi5uidocCh26QCUM3spYjGRN6PHnmJ --source_owner ~/.config/solana/dr_doobie.json --source_token_address BETCHMz1uNziNPuGYSUVE16hB2CvjLd82mgykWeF9a8R --destination_token_address 4S27vD1L5odmYa9LUZgfFwSJaYMXM5RTDNFgJxQq1XEN --amounts 100,! --release-times 1713840329,! --payer ~/.config/solana/dr_doobie.json The seed of the contract is: 3m3iWJkTeHJGkMvwrgvJhzZNcQAbwxBAwZeQdzioYzBX |
Thank you, I will share this with the team and update this thread when I learn more. |
@l1quid8 When we're talking about seed here, it's not a private key but rather a seed for the PDA as you can see here seed example. The JS example might make this a bit more clear - JS example. |
Isnt that PDA seed generation built into the CLI? I have no problems at all on devnet. The issue only occurs on mainnet. |
I was able to get it to work on mainnet running the example.ts script you mentioned. But I noticed it still doesn't work via CLI. Are there more required fields for PDA seed generation when executing from CLI? |
I've checked it on the devnet and it was fine...
But when I am trying to use it on the mainnet I am getting this preflight error
try 1
"Create Account: account Address { address: 7L2NaXgvvPuakUaprY36TxJohAakHfmER3ZGd7NVaHPr, base: None } already in use", "Program 11111111111111111111111111111111 failed: custom program error: 0x0", "Program CChTq6PthWU82YZkbveA3WDf7s97BWhBK4Vx9bmsT743 consumed 9308 of 600000 compute units"
try 2 (same error different address)
"Create Account: account Address { address: JCwi22xyPyyDDhcEYGEdJyfUvgvwvjAHAM31uwLsmZdm, base: None } already in use", "Program 11111111111111111111111111111111 failed: custom program error: 0x0"
Accounts [7L2NaXgvvPuakUaprY36TxJohAakHfmER3ZGd7NVaHPr, JCwi22xyPyyDDhcEYGEdJyfUvgvwvjAHAM31uwLsmZdm] indeed exist and belong to program CChTq6PthWU82YZkbveA3WDf7s97BWhBK4Vx9bmsT743, they been created 2 years ago..
Because of this issue I cannot create vesting on the mainnet
The text was updated successfully, but these errors were encountered: