Commit Graph

171 Commits

Author SHA1 Message Date
Colin Ogoo
393c7653c7 fix(web3.js): VoteAccount.fromAccountData() throws range error (#21091)
* fix(vote-account): rangeError [ERR_OUT_OF_RANGE] error

The web3 buffer layout is out-of-date with the current `VoteState` implementation. The buffer layout
is updated to match the structure in
https://github.com/solana-labs/solana/blob/master/account-decoder/src/parse_vote.rs

fix #20786

* docs(vote account): update reference to match new payload

* fix(vote-account): update buffer layout for prior voters

Update buffer layout for prior voters to match serialized data

* fix(vote-account): response showing buffers instead of public keys

transform buffers into public keys

* refactor(vote account): extract parsing into function calls

* feat(vote account): address PR comments

* fix(web3.js vote account): start prior voters array from given index

* fix(web3.js vote account): incorrect data for prior voters array

* Update web3.js/src/vote-account.ts

Co-authored-by: Justin Starry <justin.m.starry@gmail.com>

Co-authored-by: Justin Starry <justin.m.starry@gmail.com>
2021-11-30 13:55:21 -05:00
Aiham
88f8c89f18 Fix typo: a -> an (#21422) 2021-11-24 23:01:30 -07:00
Tyera Eulberg
6546c3cbae Fixup processed docs (#21316) 2021-11-17 06:52:09 +00:00
Ben Newhouse
7e600bd451 Fix BPF parameter alignment to work regardless of target ABI (#21271) 2021-11-16 16:02:22 +01:00
Jon Cinque
ec86ff8fb3 docs: Update language around immutable programs (#21116) 2021-11-01 21:41:49 +01:00
Colin Ogoo
521b7b79cc fix(docs): missing import (#20788)
add missing import of `Connection`
2021-10-26 11:44:00 -06:00
yihau
dec104c580 feat: update getClusterNodes 2021-10-26 10:00:28 -07:00
yihau
aa13c90dd7 feat(docs): add transactionCount to getEpochInfo response 2021-10-24 17:45:04 -07:00
Slavomir
63f94a4db3 Fix response examples for getTokenAccountsByOwner and getTokenAccountsByDelegate 2021-10-23 09:24:48 -07:00
Brian Anderson
f729dec321 Update 'Developing with Rust' GitHub links (#20860)
* Update old GitHub links in 'Developing with Rust' docs

* exclude_entrypoint -> no-entrypoint in 'Developing with Rust'
2021-10-22 01:55:46 -06:00
Brian Anderson
cc4bb5a451 Expand Rust API docs entry point (#20770) 2021-10-19 13:47:55 -06:00
Yihau Chen
185c9f9e8f fix(docs): getInflationRate epoch type from f64 => u64 (#20589) 2021-10-11 09:44:38 -06:00
Tyera Eulberg
5e431fbee2 Update deprecated snapshot/fees/blockhash api docs (#20522)
* Move and notate deprecated blockhash/fees docs

* Update getHighestSnapshotSlot note
2021-10-07 20:38:28 +00:00
Tyera Eulberg
d56ad8ff4f Update expected removal version to match backward-compatibility policy (#20515) 2021-10-07 18:51:16 +00:00
Trent Nelson
767f740305 Bump version to 1.9.0 2021-10-06 17:57:41 -07:00
Sean Young
2400e86d13 Simplify ed25519 instruction index
Allow u16::MAX to be specified for the instruction index. This makes it
possible to specify the current instruction, so it is not necessary to
know the instruction number.
2021-10-05 14:14:05 +01:00
Lijun Wang
fe97cb2ddf AccountsDb plugin framework (#20047)
Summary of Changes

Create a plugin mechanism in the accounts update path so that accounts data can be streamed out to external data stores (be it Kafka or Postgres). The plugin mechanism allows

Data stores of connection strings/credentials to be configured,
Accounts with patterns to be streamed
PostgreSQL implementation of the streaming for different destination stores to be plugged in.

The code comprises 4 major parts:

accountsdb-plugin-intf: defines the plugin interface which concrete plugin should implement.
accountsdb-plugin-manager: manages the load/unload of plugins and provide interfaces which the validator can notify of accounts update to plugins.
accountsdb-plugin-postgres: the concrete plugin implementation for PostgreSQL
The validator integrations: updated streamed right after snapshot restore and after account update from transaction processing or other real updates.
The plugin is optionally loaded on demand by new validator CLI argument -- there is no impact if the plugin is not loaded.
2021-09-30 14:26:17 -07:00
Tyera Eulberg
a70fd8e606 Update TransactionError link to docs.rs (#20145) 2021-09-23 14:55:28 -06:00
cryptogosu
b16f2da444 Added web3 reference guide (#19970)
Added web3 reference guide

Added web3 reference guide
2021-09-22 09:38:38 -04:00
cryptogosu
62189c9f3c Web3 docs updated with quickstart guide (#19457)
Web3 docs updated with quickstart guide

Web3 docs updated with quickstart guide
2021-09-13 16:42:09 +02:00
Sean Young
8b9e472a6c feat: add ed25519 signature verify program
Solang requires a method for verify ed25519 signatures. Add a new
builtin program at address Ed25519SigVerify111111111111111111111111111
which takes any number of ed25519 signature, public key, and message.
If any of the signatures fails to verify, an error is returned.

The changes for the web3.js package will go into another commit, since
the tests test against a released solana node. Adding web3.js ed25519
testing will break CI.
2021-09-05 18:59:37 +01:00
Zahin Mohammad
f68ca3895b docs: fix typo (#19646) 2021-09-04 12:26:38 -06:00
Zahin Mohammad
497b6c152f docs: fix typo (#19641) 2021-09-04 16:48:10 +00:00
Brooks Prumo
8ac94b2cf4 Add Incremental Snapshot support to RPC (#19559)
#### Problem

There's no way to get incremental snapshot information from RPC.

#### Summary of Changes

- Add new RPC method, `getHighestSnapshotSlot` that returns a `SnapshotSlotInfo`, which contains both the highest full snapshot slot, and the highest incremental snapshot slot _based on_ the full snapshot.
- Deprecate old RPC method, `getSnapshotSlot`
- Update API docs

Fixes #19579
2021-09-02 15:25:42 -05:00
Matthew Callens
d11b0abf11 fix typo in calling-between-programs developing documentation (#19502) 2021-08-30 19:17:43 +00:00
Jack May
f81bfc8462 Limit message encoding to base-64 (#19468) 2021-08-29 19:53:37 -07:00
Jack May
355a23c8f6 Deprecate old and document new RPC APIs (#19456) 2021-08-27 05:22:53 -07:00
Tyera Eulberg
7482861f4b Add parameter to allow setting max-retries for SendTransaction rpc (#19387)
* Add parameter to cap rpc send retries for a tx

* Add parameter to docs
2021-08-24 22:44:13 -06:00
Brian Anderson
9483866e0b Correct JSON-RPC docs for getSlot (#19355)
* Correct JSON-RPC docs for getSlot

* Update docs/src/developing/clients/jsonrpc-api.md

Co-authored-by: Tyera Eulberg <teulberg@gmail.com>

Co-authored-by: Tyera Eulberg <teulberg@gmail.com>
2021-08-21 00:15:50 +00:00
Trent Nelson
e0bc5fa690 validator: Trusted validators are now called known validators 2021-08-19 22:43:49 -06:00
Justin Starry
c053df143f RPC: add option to exclude accounts from get_supply (#19270) 2021-08-17 23:32:58 +00:00
0xlucius
aa688e4549 fix typo (#19111) 2021-08-06 19:52:54 -07:00
hugo
4d0cd9b283 Added missing method to index and updated token account methods docs. (#18906) 2021-07-28 16:13:06 -06:00
Stephen Peterkins
71bd434297 docs: fix link to Native Programs page in transactions.md (#18830) 2021-07-21 22:37:40 -05:00
murlux
d751d5b6e8 Fixed broken links and added more context to getTokenAccountBalance docs 2021-07-21 10:24:53 -07:00
Jack May
b13caa14c9 Update simulateTransaction rpc docs (#18762) 2021-07-19 13:53:00 -07:00
Yang Li
269028360c fix another typo 2021-07-18 06:30:40 -07:00
Yang Li
1507477306 correct typo 2021-07-18 06:30:40 -07:00
Michael Vines
c03490b24a Remove Tour de SOL more 2021-07-16 03:25:35 +00:00
Trent Nelson
bf90ea282a rpc: more params for GetVoteAccountsConfig 2021-07-14 08:41:52 +00:00
Michael Vines
4098af3b5b Record vote account commission with voting/staking rewards and surface in RPC 2021-07-12 15:09:44 -07:00
Max Ogden
ebc7df62f3 Fix example in docs for getInflationReward (#18494) 2021-07-07 18:15:56 +00:00
Ruud van Asseldonk
94ab0eb49f Document order of recent blockhashes sysvar
I wanted to use this sysvar to get a recent block hash, but I didn't
know whether the first or the last entry contains the most recent block
hash.

By calling it for mainnet, printing the results, and comparing that to
the recent blocks on solanabeach.io/blocks, I discovered that the
entries are ordered from most recent to least recent. Document this to
save future readers the trouble.
2021-07-01 22:22:52 -07:00
Tyera Eulberg
cc80197349 Update notification format info to be consistent (#18354) 2021-07-01 05:49:30 +00:00
Tiago Carvalho
8e7d393b70 Added formats to notifications in WebSocket RPC client. (#18231) 2021-06-30 22:04:37 -06:00
Tyera Eulberg
dfb6296499 Document slotsUpdates (#18335)
* Add slotsUpdates to jsonrpc docs

* Re-add unstable section
2021-06-30 21:24:08 +00:00
Jack May
8a136736ad Update sysvar docs (#18125) 2021-06-22 09:59:48 -07:00
Jon Cinque
1b1d34da59 Refactor stake program into solana_program (#17906)
* Move stake state / instructions into solana_program

* Update account-decoder

* Update cli and runtime

* Update all other parts

* Commit Cargo.lock changes in programs/bpf

* Update cli stake instruction import

* Allow integer arithmetic

* Update ABI digest

* Bump rust mem instruction count

* Remove useless structs

* Move stake::id() -> stake::program::id()

* Re-export from solana_sdk and mark deprecated

* Address feedback

* Run cargo fmt
2021-06-15 18:04:00 +02:00
Sarat Limawongpranee
3657469826 Fix typo in docs (#17920) 2021-06-14 10:33:23 -06:00
Haik Dulgarian
54155f875a minor fixes to punctuation and typos (#17881)
* fix minor typos and punctuation

* fix minor typos and punctuation

* rewording for clarity and typo corrections

* rewording for clarity and typo corrections

* rewording for clarity and typo corrections

Co-authored-by: Gregg Dourgarian <greggd@aidacreative.com>
2021-06-13 23:35:10 -07:00