Commit Graph

954 Commits

Author SHA1 Message Date
b5a735878a Sysvar account_into return program error rather than option (#8121) 2020-02-04 14:54:41 -08:00
b6d09f1901 Add BPF program entrypoint return type (#8111) 2020-02-04 12:25:42 -08:00
4e595e8e3c Facilitate printing program errors from BPF programs (#8109) 2020-02-04 09:03:45 -08:00
336d5136bf Print more program error info to user when using CLI (#8098) 2020-02-03 17:14:53 -08:00
0fd795a676 Remove program error footgun and cleaner developer experience (#8042) 2020-01-31 10:58:07 -08:00
2226c1b75c Add Rust BPF RefCell borrow helpers (#8047) 2020-01-30 20:40:27 -08:00
dd276138c2 Add support for idiomatic error handling to BPF instruction processors (#7968) 2020-01-30 09:47:22 -08:00
b19f730527 Seperate RefCells lamports and data (#8021) 2020-01-29 21:15:04 -08:00
e6803daf10 Remove support for stake redelegation (#7995)
* Remove support for stake redelegation

* fixup
2020-01-29 17:59:14 -08:00
12eff5a2f9 Cleanup SDK use syntax (#8004) 2020-01-28 16:11:22 -08:00
fed3817ed3 Update and fix transaction error documentation (#7998) 2020-01-28 15:59:50 -08:00
1596c961d9 Rust BPF program cleanup (#7990) 2020-01-27 18:27:44 -08:00
912aafcefd Reduce epoch duration from 2 weeks to 2 days 2020-01-27 10:34:55 -07:00
1b391dd36b Add account accessor functions (#7966) 2020-01-24 14:34:59 -08:00
917067741a Cleanup BPF SDK (#7965) 2020-01-24 13:41:14 -08:00
34ed93d57c Optimize account copies and use RefCell to handle duplicate accounts in BPF programs (#7958) 2020-01-24 10:54:26 -08:00
c95e5346a4 Boot the mut (#7926) 2020-01-22 17:54:06 -08:00
e54bf563b5 Avoid unsorted recent_blockhashes for determinism (#7918)
* Avoid unsorted recent_blockhashes for determinism

* Add a test: test_create_account_unsorted
2020-01-23 10:51:22 +09:00
964ff522be Verb-noun-ify Nonce API (#7925)
* Verb-noun-ify Nonce API

* Unify instruction naming with API naming

The more verbose nonce_account/NonceAccount was chosen for clarity
that these instructions work on a unique species of system account
2020-01-22 16:31:39 -07:00
ce70d6eedc Add redeem_vote_credits to runtime (#7910)
* Move redeem_vote_credits into runtime

* fixup

* test

* move stake manipulation to stake program

* chugga for less indentation
2020-01-22 12:21:31 -08:00
023074650f Allow the same account to be passed multiple times to a single instruction (#7795) 2020-01-22 09:11:56 -08:00
3aabeb2b81 Rename bootstrap leader (#7906)
* Rename bootstrap leader to bootstrap validator

It's a normal validator as soon as other validators enter the
leader schedule.

* cargo fmt

* Fix build

Thanks @CriesofCarrots!
2020-01-22 09:22:09 -07:00
52bc4a3598 nudge (#7887) 2020-01-20 15:27:36 -08:00
470d9cd752 Add system_instruction::{allocate, allocate_with_seed, assign_with_seed}, (#7847)
* cleanup test checks cargo audit

* Add system_instruction allocate

* fixup

* fixup
2020-01-17 09:29:15 -08:00
da165d6943 Fix Rpc inconsistencies (#7826)
* Update rpc account format: remove byte arrays

* Base58-encode pubkeys in getStoragePubkeysForSlot

* Update docs
2020-01-15 15:33:53 -07:00
6d3b8b6d7d Remove tuples from JSON RPC responses (#7806)
* Remove RpcConfirmedBlock tuple

* Remove getRecentBlockhash tuple

* Remove getProgramAccounts tuple

* Remove tuple from get_signature_confirmation_status

* Collect Rpc response types

* Camel-case epoch schedule for rpc response

* Remove getBlockCommitment tuple

* Remove getStorageTurn tuple

* Update json-rpc docs
2020-01-15 00:25:45 -07:00
ff1ca1e0d3 Consolidate entry tick verification into one function (#7740)
* Consolidate entry tick verification into one function

* Mark bad slots as dead in blocktree processor

* more feedback

* Add bank.is_complete

* feedback
2020-01-15 09:15:26 +08:00
5f4e0c7e3e Naming nits (#7798)
automerge
2020-01-14 13:38:17 -08:00
81ae44f858 Nonce: Rename instructions with VerbNoun scheme (#7775)
automerge
2020-01-13 15:34:43 -08:00
08ba27627d Direct entrypoint for execution (#7746) 2020-01-10 13:20:15 -08:00
6775e83420 Add create with seed to cli (#7713)
* Add create with seed to cli

* nonce and vote, too
2020-01-09 15:22:48 -08:00
09cff5e4cc Cleanup usage of feature "program" (#7712) 2020-01-08 13:49:35 -08:00
7e94cc2cc3 Move nonce into system program (#7645)
automerge
2020-01-03 16:34:58 -08:00
75d94240ed account_info utilities (#7666) 2020-01-03 09:14:51 -08:00
6c544708e1 Add safety docs (#7665) 2020-01-03 09:14:28 -08:00
6ca575b5a3 Make sol-to-lamport const name more clear (#7641)
automerge
2019-12-30 11:28:41 -08:00
e1ebaa902b Add base pubkey to create_account_with_seed (#7636) 2019-12-29 16:42:24 -08:00
44e45aa090 Support nonced transactions in the CLI (#7624)
* Support nonced transactions in the CLI

* Update nonce.rs
2019-12-27 14:35:49 -06:00
120c8f244c Add slot_history for slashing (#7589)
* Add slot_history for slashing

* fixup

* fixup
2019-12-23 12:23:45 -08:00
a7040896f0 Update to rust 1.40.0 (#7572)
* Update to rust 1.40.0

* fixups
2019-12-19 23:27:54 -08:00
2ebfab8e07 Remove duplicate def of MAX_SLOT_HASHES (#7574) 2019-12-19 21:24:12 -08:00
3c361eb759 Check account hashes in snapshot (#7559)
* Check for incorrect hash value

* Finish up checking for incorrect hash value

* Fix comment a bit

Co-authored-by: sakridge <sakridge@gmail.com>
2019-12-20 09:39:30 +09:00
ff171baa67 Add show-block-production command 2019-12-19 00:02:11 -07:00
0ea2843ec9 Durable Nonce - Authorized Noncer (#7417)
* Durable Nonce: Add authorized noncer to initialize instruction

* CLI: Adapt to nonce authority

* Durable Nonce: Introduce Authorize instruction

* Specify who needs to sign  ix

* 'authorized-noncer' -> 'nonce-authority'

* Document signing authority for all instructions
2019-12-17 09:34:21 -05:00
f05860672c Add create-address-with-seed to solana-cli (#7472)
* Add create account with seed to cli

* clippy

* fixup
2019-12-14 04:38:24 -08:00
777ae3c215 Add time since genesis to sysvar::clock (#7289)
* genesis timestamp

* remove clock::create_account()

* ..

* add configure-able creation time

* dividing by 1T, should be dividing by 1B
2019-12-12 14:03:43 -08:00
ea0ba19089 Add SystemInstruction::CreateAccountWithSeed (#7390)
* address generator

* coverage

* fixups

* remove ascii restriction

* illustrate that utf-8 doesn't expand the space
2019-12-12 11:12:09 -08:00
c4f3bb9b67 Use term dapp only in places where the application needs to run entirely on-chain (#7446) 2019-12-12 10:38:09 -07:00
7f6fc74c36 Remove workaround of old Rust-BPF (#7422) 2019-12-10 23:19:13 -08:00
7d6777a96f show rent model (#7410) 2019-12-10 14:50:55 -08:00