947 Commits

Author SHA1 Message Date
Greg Fitzgerald
ca2ac1e5ea Remove a mostly unused Transaction constructor 2019-03-26 15:46:58 -07:00
Rob Walker
215b07c1a9
remove status_cache.freeze (#3506) 2019-03-26 11:56:25 -07:00
Greg Fitzgerald
df333e8b6e Move new_move_many to SystemInstruction 2019-03-26 09:22:29 -07:00
Greg Fitzgerald
573dec63da Fix runtime benches 2019-03-25 14:32:01 -06:00
Greg Fitzgerald
b53cbdd9e6 Punt on the Script abstraction
Low ROI
2019-03-24 14:52:06 -06:00
Greg Fitzgerald
acedf4ca5a Move Instruction into its own module 2019-03-23 20:31:55 -07:00
Rob Walker
31b8743052
delay freeze of status_cache until squash (#3453) 2019-03-22 22:14:56 -07:00
Sathish
06b0c98c75
Remove accounts when the fork is removed (#3384)
* Fix test

* Cleanup accounts when the fork is removed

* Update test to check for deleted accounts
2019-03-21 17:36:10 -07:00
Greg Fitzgerald
d2415613de Migrate loader tests to BankClient 2019-03-21 09:19:24 -06:00
anatoly yakovenko
148e08a8a5
Enable cluster tests (#3372)
* Cluster tests

* stable!

* fixup! stable!

* fixup! fixup! stable!

* fixup! fixup! fixup! stable!

* fixup! fixup! fixup! fixup! stable!

* fixed space

* add getNumBlocksSinceSignatureConfirmation entry for the json rpc docs

* Check in upcoming epochs for potential leadership slots in next_leader_slot()
2019-03-21 07:43:21 -07:00
Stephen Akridge
bcb190a12a Remove erroneous comment 2019-03-20 16:15:25 -07:00
Stephen Akridge
4126461f87 Fix dupe port on cluster_info
and remove unintended grow file
2019-03-20 14:17:21 -07:00
Rob Walker
3048de18bb
add doc that should have been copy-pasta'd from bench (#3389) 2019-03-20 11:10:42 -07:00
Rob Walker
df9fd2bc0b
stop copying Blooms (#3379)
* stop copying Blooms

* fixup

* clippy
2019-03-20 11:06:39 -07:00
Michael Vines
0dc364c17a Relocate transaction reference verification to join the other validity checks 2019-03-20 07:46:01 -07:00
Michael Vines
da77789881
Revert "Drop 'unchecked' from get_subset_mut()"
This reverts commit 70b21b3795470dbff322d71ebda47446a4451959.
2019-03-19 17:52:02 -07:00
Greg Fitzgerald
94b5835738 Make AccountMeta a traditional struct instead of a tuple struct 2019-03-19 17:22:39 -06:00
Greg Fitzgerald
a4652a9aaf Label tuple with AccountMeta 2019-03-19 17:22:39 -06:00
Michael Vines
70b21b3795 Drop 'unchecked' from get_subset_mut() 2019-03-19 16:12:53 -07:00
Carl
5e21268ca0 PR comments 2019-03-18 20:46:11 -07:00
Carl
b38e3bef01 Modify bank_forks to support squashing/filtering new root and also don't remove parents from bank_forks when inserting, otherwise we lose potential fork points when querying blocktree for child slots 2019-03-18 20:46:11 -07:00
Greg Fitzgerald
f16f88873d Add multiple signer support to BankClient 2019-03-18 16:07:45 -06:00
Greg Fitzgerald
8d032aba9d Merge InstructionError and ProgramError
From the user's perspective, it's just an instruction error.
For program-specific errors, we still have
InstructionError::CustomError.
2019-03-18 10:39:20 -06:00
Greg Fitzgerald
122c7bc2ef Rename TransactionCompiler to Script and use it to replace the type alias 2019-03-18 08:22:54 -07:00
Greg Fitzgerald
0c0716abfb Move Bank-based tests into unit-tests 2019-03-18 08:22:54 -07:00
Greg Fitzgerald
c09accb685 Rename StaticEntrypoint to ProcessInstruction 2019-03-18 08:22:54 -07:00
Greg Fitzgerald
ae4d14a2ad Introducing Scripts
A sequence of instructions. A client compiles the script and then uses
the compiled script to construction a transaction. Then it adds a
adds a blockhash, signs the transaction, and sends it off for
processing.
2019-03-18 08:22:54 -07:00
Greg Fitzgerald
55cdbedb52 Allow tests to add instruction processors
Make runtime a private module again.
2019-03-18 08:22:54 -07:00
Greg Fitzgerald
ee39f31d81 Add Runtime object. Allow any number of static loaders. 2019-03-18 08:22:54 -07:00
Greg Fitzgerald
70b45de012 Get access to runtime errors in Budget unit-tests 2019-03-18 08:22:54 -07:00
Sathish
9566a5cc68
Organize accounts on a per fork basis (#3336)
* Organize accounts by fork

* Keep track of vote accounts in account info

* update comments
2019-03-16 23:42:32 -07:00
Greg Fitzgerald
24d9138067 Abandon Builder pattern 2019-03-15 14:46:44 -06:00
Greg Fitzgerald
aca739b800 Boot fees from TransactionBuilder 2019-03-15 14:46:44 -06:00
Greg Fitzgerald
e091aa87ea More precise constructor names 2019-03-15 14:46:44 -06:00
Greg Fitzgerald
968022a1b0 Instruction name swap
* Instruction -> GenericInstruction
* Instruction<u8, u8> -> CompiledInstruction
* Instruction<Pubkey, (Pubkey, bool)> -> Instruction
2019-03-15 14:46:44 -06:00
Greg Fitzgerald
42d5dde5b1 new_singleton -> new_with_instruction 2019-03-15 09:06:54 -06:00
Greg Fitzgerald
142eeffe5d Add BankClient to minimize copypasta 2019-03-15 09:06:54 -06:00
Greg Fitzgerald
73bd396dfb Rewrite system integration test
Create Client helpers instead of Bank helpers.
2019-03-15 09:06:54 -06:00
Greg Fitzgerald
7b4568b9bf Migrate to sign_checked() 2019-03-15 09:06:54 -06:00
Sagar Dhawan
3f2fc21bb3
Rename hash_queue and fix boundary condition (#3289) 2019-03-14 11:56:36 -07:00
Greg Fitzgerald
c1eec0290e
Rename userdata to data (#3282)
* Rename userdata to data

Instead of saying "userdata", which is ambiguous and imprecise,
say "instruction data" or "account data".

Also, add `ProgramError::InvalidInstructionData`

Fixes #2761
2019-03-14 10:48:27 -06:00
Greg Fitzgerald
e58220282a Move TransactionError into the SDK 2019-03-13 21:26:57 -06:00
Greg Fitzgerald
4ca4038d54 Rename BankError to TransactionError 2019-03-13 21:26:57 -06:00
Greg Fitzgerald
150cd31ec0 Blur the line between Bank and Runtime 2019-03-13 21:26:57 -06:00
Greg Fitzgerald
6fd0d4dcf5 Boot error piggybacking on BankError 2019-03-13 21:26:57 -06:00
Greg Fitzgerald
296415945a Generalize error codes 2019-03-13 21:26:57 -06:00
Greg Fitzgerald
1de5ae1ef0 Remove SystemError from ProgramError 2019-03-13 21:26:57 -06:00
Greg Fitzgerald
6a89c68a1d Add utility function to help get System error out of ProgramError 2019-03-13 21:26:57 -06:00
Greg Fitzgerald
c14cce4c85 Add InstructionError for runtime instruction errors 2019-03-13 21:26:57 -06:00
carllin
af03df38b9
Don't vote for empty leader transmissions (#3248)
* Don't vote for empty leader transmissions

* Add is_delta flag to bank to detect empty leader transmissions

* Plumb new is_votable flag through replay stage

* Fix PohRecorder tests

* Change is_delta to AtomicBool to avoid making Bank references mutable

* Reset start slot in poh_recorder when working bank is cleared, so that connsecutive TPU's will start from the correct place

* Use proper max tick height calculation

* Test for not voting on empty transmission

* tests for is_votable
2019-03-13 14:06:12 -07:00