5
votes
Accepted
How to verify data on chain with Solana
The solution is to use something called Program Derived Addresses.
What Are They?
Your program has its own unique address space to which it can allocate Program Derived Addresses. These are derived ...
3
votes
Blocks on testnet have no transactions
The transactions field in UIConfirmedBlock being of type Option means that this field can either contain some data (Some(LongTransactionType)) or be empty (None). If you're consistently getting None, ...
2
votes
Accepted
Connection to solana cluster using the ThinClient of the rust client library giving timeout error?
It looks like the tpu address is most likely incorrect. When you start your local validator, it should give the address, ie:
solana-test-validator
Ledger location: test-ledger
Log: test-ledger/...
2
votes
Buffer undefined when using Javascript SDK in Cloudflare Worker
You'll have to add a shim for Buffer.
Install @rollup/plugin-inject and import it into vite.config.js
import inject from '@rollup/plugin-inject';
Add a build property to the config object:
build: {
...
2
votes
Accepted
Blocks on testnet have no transactions
If you want to fetch devnet transactions, you need to change your API to point to that cluster https://api.devnet.solana.com
As the name suggests, the EncodedTransactionWithStatusMeta is the encoded ...
1
vote
Accepted
AttributeError: 'dict' object has no attribute 'encoding' when trying to pull transfers for a token
You either need to manually add encoding value in your opts dictionary or simply use TokenAccountOpts and pass it in your options.
Specifying "encoding" for get_token_accounts_by_owner ...
1
vote
Proper usage of `getProgramAccounts` via Rust SDK. Cannot execute RPC call from SDK
If you read the first error message, it complains about the returned data being too large for base58.
// Err(ClientError { request: Some(GetProgramAccounts), kind: RpcError(RpcResponseError { code: -...
1
vote
Accepted
Proper usage of `getProgramAccounts` via Rust SDK. Cannot execute RPC call from SDK
The only way how I managed to retrieve the data I wanted, was to bypass the get_program_accounts helper on the SDK client, as it was unable to properly parse the returned data. Here is the code that ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
solana-client-sdk × 8solana-client × 3
anchor × 2
rust × 2
solana-sdk × 2
solana-program × 1
rpc × 1
transfer × 1
anchor-client × 1
python × 1
javascript × 1
address × 1
api × 1
wsl × 1
node.js × 1
publickey × 1
solana-program-test × 1