Skip to main content

Questions tagged [solana-program]

The tag has no usage guidance, but it has a tag wiki.

Filter by
Sorted by
Tagged with
0 votes
0 answers
8 views

How create testnet faucet?

There is an idea to create your own Solana testnet faucet. Can you please tell me the links to the manuals?
S.Miller's user avatar
1 vote
1 answer
10 views

Getting Error: memory allocation failed whenever serializing the data to insert into the account

I am developing a program on Solana and I have to store around 1 MB of state into the account (Given accounts can store up to 10 MB of data) however, whenever I try to serialize that data to add it to ...
Ghazanfer Anwar's user avatar
1 vote
1 answer
17 views

Transactions for providing liquidity to Raydium pools consistently failing

I recently began to deposit tokens into liquidity pools on the Raydium decentralized exchange, which initially succeeded with minimal issues, but today I was not able to deposit any further liquidity. ...
Code man's user avatar
1 vote
0 answers
21 views

Is the SVM single-threaded

In my understanding, the Solana runtime creates new instances of the SVM for each transaction, due to this, I can't help but wonder if the SVM is actually single-threaded. I know the Solana runtime ...
fikunmi's user avatar
  • 63
1 vote
0 answers
19 views

How to link a smart contract to a dedicated wallet

I have a question about linking a wallet to a smart contract. Specifically, I want to send tokens to a program wallet and then have that wallet send tokens to another recipient in a subsequent ...
GoT's user avatar
  • 65
1 vote
0 answers
30 views

How to obtain the trading volume of smaller Solana tokens like memecoins using Python?

I am developing an application to collect information on memecoins on the Solana network and am already using libraries such as solders and solana-py. However, I have not yet found a viable way to ...
Rafael Peres's user avatar
1 vote
0 answers
18 views

Access violation in unknown section at address 0x0 of size 8

I'm encountering Access violation in unknown section at address 0x0 of size 8 error when I call my initialize instruction. Here is the full error. Message: Transaction simulation failed: Error ...
Jung Chun's user avatar
0 votes
1 answer
17 views

How to verify priority fees

I have tested my transactions with 10k, 100k, 200k lamports priority fees. I am unable to come to any conclusions that setting higher priority fees will optimise the time it takes. I am getting varied ...
Pranav Desai's user avatar
0 votes
0 answers
21 views

Simple program fails Error: memory allocation failed, out of memory, consumed 2474 of 200000 compute units

I'm trying to write a program to be able to init and mint different tokens. So I pass dynamic seed during program invocation as a parameter, but somehow running out of memory in the mint_tokens ...
Scott's user avatar
  • 33
1 vote
1 answer
17 views

Why do transactions duplicate the accounts used?

I'm looking at the structure of a Solana transaction and it seems a few bytes are wasted by duplicating the list of accounts used. From my understanding, first the public key of all transactions are ...
fikunmi's user avatar
  • 63
-1 votes
0 answers
54 views

Do You Know How to Get a List of Holders? I Found an Easy, Quick, and Simple Tool to Use

how’s it going? A friend told me about a very interesting tool that helps you get a list of holders in just 5 steps. There’s a site called Smithii that offers many tools for token creators. One of ...
Vicente Roca's user avatar
0 votes
0 answers
9 views

ambiguity inside solana's GetAccountInfo rpc

I'm confused while using rpc getAccountInfo because the value of the answer will always be null when the Solana balance is 0. This happens even when the address is new and the account has multiple ...
Andrea Hinata's user avatar
1 vote
1 answer
20 views

When you attempt to send SOLto an address that doesn't yet exist on the network,what will happen?

the network will automatically create the account for that address when it receives the tokens.is that right?who will affort to create the receiver address account?
qimeila's user avatar
  • 11
2 votes
0 answers
25 views

Solana node laggin in sync

This is my configuration for the node:- #!/bin/bash export SOLANA_METRICS_CONFIG="host=https://metrics.solana.com:8086,db=mainnet-beta,u=mainnet-beta_write,p=password" exec solana-validator ...
Yash Goel's user avatar
0 votes
0 answers
21 views

anchor test fails at initialize instruction which initializes token 2022 accounts

I'm writing typescript anchor test code about my initialize instruction, it fails with this error. Is initialized!: Error: AnchorError caused by account: system_program. Error Code: ...
Jung Chun's user avatar
0 votes
0 answers
19 views

How can I add liquidity for a token I want in a Raydium CPMM pool?

require('./globals'); const { Percent } = require('@raydium-io/raydium-sdk-v2'); const BN = require('bn.js'); const Decimal = require('decimal.js'); const { lpBotServices, raydiumServices } = require('...
Akash Yadav's user avatar
1 vote
1 answer
17 views

How to generate a random number based on clock and recent blockhash?

i want to generate a random number in native rust on solana by using clock and recent blockhash. Right now I'm simply generating it by let clock = Clock::get()?; let random_number = (clock.slot % 100) ...
user22198's user avatar
3 votes
1 answer
49 views

Using solana-program-test, but stuck at initialize instruction

I'm new to Solana development, and I'm stuck with testing my initialize instruction. My initialize instruction is not complicated. I'm getting this error. thread 'test_initialize' panicked at /Users/...
Jung Chun's user avatar
0 votes
0 answers
9 views

filtering buy txns with timestamp

are there any APIs or any way to filter buy transactions for a certain token by timestamp? I don't want to paginate through transactions, just filter them by timestamp.
0xkali's user avatar
  • 23
2 votes
0 answers
20 views

Unable to generate build in anchor , want to know the stable version of solana-sdk and solana-client compaitable

what should be the version of crates, since I am getting error of async-trait all time error: failed to select a version for the requirement `async-trait = "^0.1.77"` The version ...
hammad ali's user avatar
0 votes
0 answers
9 views

Are there any Examples of Offset curve based AMM in the wild

The offset curve can be seen as a combination of the constant price and constant product curve. It follows the constant product curve dynamics, but allows for the pool creator to set an "offset&...
Moresh Kokane's user avatar
0 votes
0 answers
10 views

Exploring Tokenization and Data Security Solutions with Solana

We are very interested in exploring how Solana can be used for two specific applications for our customers: Tokenizing Intangible Assets: We would like to understand how to use Solana to tokenize ...
Alpha Quantum's user avatar
0 votes
1 answer
25 views

Adding Set Authority Feature To SPL Token Creator

Recently our team completed a token launcher platform for EVM tokens, now we want to create a another platform for creating SPL tokens. I'm not very familiar with Solana, but I've found some starting ...
DeFiDevJimmy's user avatar
0 votes
0 answers
59 views

Buy pumpfun error

When I use https://docs.pumpapi.fun/trade_transaction_api this docs generate pumpfun transaction And I sign and send the transaction this is my transaction data. const data = { trade_type: 'buy',...
Huaming Li's user avatar
0 votes
1 answer
11 views

Transfering sol from pda to a hardcoded account pubkey

Can i transfer money from a program owned PDA to a hardcoded pubkey without AccountInfo of the receiver ? Or do I NEED to pass it from the client? let hardcoded_pubkey = Pubkey::from_str("----...
DumSolProgramer's user avatar
0 votes
0 answers
19 views

Metadata on solscan not showing up

I created my metadata with createMetadataAccountV3 with the tx being recorded onchain her, but i am still not able to view my token metadata on solscan. I am able to view the icon on phantom wallet ...
Soh Jian Hao's user avatar
1 vote
1 answer
18 views

Transfering money from a pda to a user wallet with native rust

Sorry for a noob question but im writing a solana program without anchor. And I'm having a problem with transfering sol from pda to a wallet in a program. pub fn process_instruction( program_id: &...
user21930's user avatar
0 votes
1 answer
27 views

How to fix "instruction tries to borrow reference for an account which is already borrowed" error

I'm writing a native solana program and from this code fragment i'm getting error: "instruction tries to borrow reference for an account which is already borrowed" invoke_signed( &...
user21922's user avatar
0 votes
0 answers
10 views

How to airdrop sols in Rust test case using tokio framework

I am working over the airdrop over a particular Keypair to perform testing using rust. Signature is being generated but Transaction is not confirmed #[cfg(test)] // pub mod utils; mod tests { use ...
hammad ali's user avatar
2 votes
1 answer
82 views

How to create shard accounts to manage "unlimited" account size

Since there is a limitation inside Solana transactions (1kb), and Solana account (1Mb), I'm not able to create a huge account ^^ Someone suggests me to open a new question: Handle big vector ...
GoT's user avatar
  • 65
0 votes
1 answer
25 views

What is the dead address on Solana for burning tokens?

I was making a research on a meme token on Solana and I saw that the dev sent about 13% of the token supply to this address 1nc1nerator11111111111111111111111111111111. I want to know if that is a ...
Bosskidz's user avatar
0 votes
1 answer
19 views

Update token logo

I need help updating my token logo on Solscan. When I try to update it, I see an error message saying "Immutable denied."
Hagher Tersoo's user avatar
0 votes
1 answer
23 views

Issue with Solana onLogs and removeLogsListener when splitting code into separate files

I am working on a project using Solana web3.js with the QuickNode API. I have split my code into two files, track.js and remove.js, to keep it organized. However, I am encountering an issue when ...
Mustapha Abdulrohim's user avatar
0 votes
0 answers
14 views

How to send transaction from wallet with secret key

I am trying to send a transaction from a wallet using secret key. I am trying to execute it using @solana/web3.js. Here's the script that I have created but it is not working for some reason. "...
Anas's user avatar
  • 41
0 votes
1 answer
40 views

Smart Program test anchor

here in my instruction it need two things one is signer and other is a PDA account right? PIC 1 but in here while i'm testing i'm not able to pass the todoPda account as you can see it's showing some ...
iamjoey.sol's user avatar
0 votes
0 answers
6 views

How Pyth is able to update each feed contract every block?

How they garantee the TX successful landing? Running their own validator would increase the certainty of landing the tx? Looks like they are sending the transaction here.
pplanel's user avatar
1 vote
0 answers
14 views

Account Serialization error in `spl-stake-pool`'s add-validator instruction

I'm trying to Add validator to my stake-pool through a program, When i try to do that i get this error i use version 2.0.0 of stake-pool and version 2.0.0 of solana I use this instruction in my ...
Abhishek Faliya's user avatar
1 vote
1 answer
20 views

How to deserialize StakePool account data on a solana native program on chain?

let stake = try_from_slice_unchecked::<StakePool>(&stake_pool.data.borrow())?; i have tried try_from, try_from_slice,unchecheked and with schema as well, but I get this same error, the ...
Abhishek Faliya's user avatar
0 votes
3 answers
75 views

Anchor detecting wrong Rust version

Anchor keeps detecting my Rust version as 1.68.0-dev even though it is the newest one, any idea? jano@Jans-MacBook-Pro counter_2 % anchor test warning: /Users/jano/Desktop/projekty/programowanie/...
user21619's user avatar
3 votes
1 answer
84 views

Handle big vector containing ton of structs

I'm looking for a way to handle a big struct. I want to understand how to create an account storing more than 10_000 structs inside is possible. Is there a simple way to do it? Or should I have to ...
GoT's user avatar
  • 65
0 votes
0 answers
17 views

when i am creating 'create-extra-metas' using cli i am getting 'invalid program argument' Error

../../target/debug/spl-transfer-hook create-extra-metas HooGStFZgkeZ5wCSg9vHtuEYBSotB26tVEvXra4PEKYJ MoxLrhGXAjVnEiVAjG5ycQbp9MVd4sjfj1yLPFVXhkh error: send transaction: error: send transaction: RPC ...
Mohammad Abuzar's user avatar
1 vote
0 answers
13 views

"Anchor deploy" deploys immutable program

I am using Anchor 0.30.1 which is the latest version. I used to use Anchor 0.30.0 and anchor deploy has deployed upgradeable programs. But after upgrading to 0.30.1, it deploys immutable program. ...
Julbh's user avatar
  • 138
1 vote
1 answer
26 views

Use custom transfer function instead of Spl Token::transfer

I am creating a new token and gonna list it on some DEX platforms where user can buy my token. What i want is when a user gonna buy my token from any platform the transfer function should be my custom ...
Mohammad Abuzar's user avatar
0 votes
1 answer
35 views

How to handle connection failures with "onLogs"?

I am using onLogs (https://solana-labs.github.io/solana-web3.js/classes/Connection.html#onLogs) to listen to interactions with my program. I am connecting to the blockchain via a paid RPC and ...
OSF's user avatar
  • 3
0 votes
1 answer
32 views

how to create Token account from solana wallet adapter

I want to send the tokens from the frontend, how can I create the ATA account for destination address?
Bobz's user avatar
  • 514
0 votes
0 answers
32 views

Feepayer issue while swap

I am facing the issue while swapping the tokens using Jupiter API, I want to swap from other and feepayer will be another account. while swapping the feepayer account error show: Error Swap: Cannot ...
Bobz's user avatar
  • 514
0 votes
0 answers
16 views

Phantom Wallet Recovery

i just register wallet at the first July 2024 , and i didnt save the secert recovery phrase , i have link the account game Backwood with my Twitter and Discord , i still use this mac address , your ...
Hoa's user avatar
  • 1
0 votes
1 answer
23 views

Unable to deploy a Hello World contract

I have created a very simple Hello World using anchor framework, rust, and Solana. But I am unable to deploy it, due to rust's version discrepancy. Refer the below image I have tried all types of ...
ispostback's user avatar
0 votes
1 answer
28 views

Performance test in solana local testnet

I'm testing the performance of testnet, but I cannot get higher than 530 tps on token swap smart contracts (enabling parallel executions by deploying multiple instances). It seems that the test ...
gold mountain's user avatar
0 votes
1 answer
27 views

Deserializing Anchor Account Data

The IDL from anchor is this { "name": "GlobalVotes", "type": { "kind": "struct", "fields": [ { "name": &...
taborgreat's user avatar

1
2 3 4 5
28