How to trigger a wallet connect from onClick with solana-web3.js or...
I have code like this:const { publicKey, sendTransaction } = useWallet()... some code, then this: try { if (!publicKey) {And in that if (!publicKey) { I want to trigger wallet connect.The thing above....
View ArticleWhen ever I run anchor init, I get this error, I have discarded serveral...
error: failed to parse lock file at: /home/mfoniso/Desktop/code/SOL/mycalculatordapp/Cargo.lockCaused by:lock file version 4 was found, but this version of Cargo does not understand this lock file,...
View ArticleTokens with onchain data
I am wondering if it is possible to craft a type of token which seems to be a mix of existing existing standards. I cant seem to find it in any documentation. For reference, it is probably similar to...
View ArticleWhy does Phantom block developers from using Solana?
Are you aware that Phantom blocks new projects on Solana by marking them as malicious sites, even when these projects have no harmful code, functions, or intentions?There are no guidelines provided to...
View ArticleBallance suddenly sent to unknown wallet
I try to sent a fiew of solana to my wallet account but suddenly it sent to unknown wallet without my any permission,what should i do?
View ArticleError using concurrent merkle tree: Invalid root recomputed from proof when...
"Here's my code - I want to update the metadata of my cNFT""This is the error I received after executing the method""Here are the reference materials I'm using"
View ArticleTokenAccountNotFoundError after calling getOrCreateAssociatedTokenAccount
I have an API route where I generate a new wallet with web3.Keypair function. Then I want to getOrCreateAssociatedTokenAccount for my spl token and get the balance. The first few times I call this API...
View ArticleFailure in transferring SPL tokens from one account to another inside Solana...
Here's my Solana Program. It defines the logic for staking SPL tokens.use anchor_lang::prelude::*;use anchor_spl::{ token::{TokenAccount, Mint,Token, Transfer, transfer, Approve},...
View ArticleTokenAccountNotFoundError from getOrCreateAssociatedTokenAccount
Error I'm getting: TokenAccountNotFoundErrorIt happens at getOrCreateAssociatedTokenAccount, I had checked other posts with same issue where they had to change commitment to "confirmed", but that...
View Articlesolana sendRawTransaction sometimes fail, sometimes success
i got a problem when i broadcast the rawTransaction by the solana-api.it always return the txHash for me and it correct for the calculate first signature. but i can't found it on the explorer, and my...
View ArticleHow to generate and save a keypair with solana/web3.js v2?
I'm trying to generate a keypair and reuse it as a payer with the new web3.js.import { generateKeyPairSigner } from "@solana/web3.js";const keypair = await generateKeyPairSigner();console.log("keypair:...
View ArticleGetting "Invalid Arguments" error while sending versioned transaction...
I am using "@solana/web3.js": "^1.90.0".While sending versioned transactions I am getting "Invalid Arguments". I have a retry logic in place that retries failed transactions with the same arguments...
View ArticleTransaction not confirmed
I used python to write a program that performs swaps on solana using Jupiter V6 aggregator, the transaction gets signed and it gives a hash, but the transaction never gets confirmed and if use the hash...
View ArticleDo I need websockets for sendAndConfirmTransaction() in web3.js version 2?
Do I need websockets for sendAndConfirmTransaction()?In web3.js version 1, a websocket connection wasn't necessary. However in V2, sendAndConfirmTransactionFactory() requires an rpcSubscriptions...
View Articleneed a better way to analyse tests working for transactions that exceed timeout
I am using anchor, bankrun and jest to test my contract on solana. How can I get better errors or exact problems in my tests.codeimport { startAnchor } from "anchor-bankrun";import { PublicKey } from...
View ArticleHow do I send transactions with new web3.js?
I've been trying to create & send transactions like this, but I'm gettingSolanaError: JSON-RPC error: Invalid method parameter(s) (invalid base58 encoding: InvalidCharacter { character: '+', index:...
View ArticleMinting Metaplex NFTs in an Anchor Program using PDAs
I am trying to mint Metaplex NFTs in an Anchor program. Unfortunately it seems that the provided seeds don't result in a valid address.Here is my program:use anchor_lang::prelude::*;use...
View ArticleUpdating Token Icon
How can I update our token icon on phantom? We recently updated it. Since it was launched on pumpkin I understand it may be immutable but I’ve seen it done with other projects including Retardio.
View ArticleRaydium swap: Program log: Error: Invalid Sign Account
Just created instruction to swap on raydium v4 in golang and when i try to send the transaction, have this error:Program log: Error: Invalid Sign Accountchecked my public and private key and are...
View Article