Skip to content
This repository was archived by the owner on Nov 15, 2023. It is now read-only.
Merged
Changes from 1 commit
Commits
Show all changes
107 commits
Select commit Hold shift + click to select a range
8bb5143
decl_module and extract runtime mod
pepyakin Jul 4, 2018
7fa574f
Invert dependency staking←→contract
pepyakin Jul 4, 2018
8c06e98
Remove CodeOf
pepyakin Jul 4, 2018
f315ca0
Remove StorageOf and move double_map
pepyakin Jul 4, 2018
799e591
Comment staking test
pepyakin Jul 4, 2018
92922fd
Clean
pepyakin Jul 4, 2018
d43ab98
Add gas_price and gas_limit
pepyakin Jul 4, 2018
92cfeeb
Commit.
pepyakin Jul 4, 2018
a4264f3
Renames
pepyakin Jul 4, 2018
9d07af9
Params
pepyakin Jul 5, 2018
00919a4
WIP
pepyakin Jul 5, 2018
900c859
Rename transfer to call
pepyakin Jul 6, 2018
593d51c
WIP
pepyakin Jul 11, 2018
0b501c6
Rebuild binaries.
pepyakin Jul 11, 2018
ce0e128
WIP
pepyakin Jul 11, 2018
8915d76
Backport ctro changes
pepyakin Jul 11, 2018
ca48073
Call wiring
pepyakin Jul 12, 2018
3f2423f
Commit overlay.
pepyakin Jul 13, 2018
32b0e55
Rename merge → commit, into_state → ..._change_set
pepyakin Jul 13, 2018
8577fad
WIP
pepyakin Jul 14, 2018
14ee2f4
Contract creation routines
pepyakin Jul 14, 2018
3a218d9
Set code of the created account.
pepyakin Jul 14, 2018
e8157c6
Fix the ID of `create` Call
pepyakin Jul 14, 2018
43508cd
Fix most of the warning.
pepyakin Jul 14, 2018
a4b6480
Add the simplest test in the contract crate
pepyakin Jul 14, 2018
a340742
Transfers work!
pepyakin Jul 14, 2018
e3b906c
Add contract_create test.
pepyakin Jul 14, 2018
8a541a3
Clean
pepyakin Jul 14, 2018
77ee25b
Add top-level create test
pepyakin Jul 14, 2018
30a72d3
Clean a bit.
pepyakin Jul 14, 2018
51ee15d
Pass gas_limit and data via create.
pepyakin Jul 14, 2018
9c1c246
Introduce OnAccountKill callback in staking
pepyakin Jul 14, 2018
3d3a4b7
Hook up OnAccountKill
pepyakin Jul 14, 2018
6ccefe6
Comments
pepyakin Jul 14, 2018
856de95
Pay for gas.
pepyakin Jul 15, 2018
b3c256b
Refund unused gas in call
pepyakin Jul 15, 2018
18a36a3
Tests for zero call and zero endownment.
pepyakin Jul 15, 2018
1872173
Add todo about rewriting docs
pepyakin Jul 15, 2018
8be77ad
Pay for gas in create transactions
pepyakin Jul 15, 2018
0df8491
Fix refunds
pepyakin Jul 15, 2018
25492de
Clean unrelevant comments
pepyakin Jul 15, 2018
f3a2ebf
fixup! Fix refunds
pepyakin Jul 15, 2018
ea2254d
fixup! Clean unrelevant comments
pepyakin Jul 15, 2018
315c0ea
Move DetermineContractAddress to contract
pepyakin Jul 15, 2018
3ab381c
fixup! Clean unrelevant comments
pepyakin Jul 15, 2018
b513597
Inline effect_transfer, remove effect_create
pepyakin Jul 15, 2018
cdb2eeb
Merge 'origin/master' into ser-contract-ioc
pepyakin Jul 15, 2018
d54cec0
Use own new_test_ext.
pepyakin Jul 15, 2018
4032b2f
Don't account for liability
pepyakin Jul 15, 2018
3dfd294
Add some docs
pepyakin Jul 16, 2018
f276d52
Move contract_fee into contract module
pepyakin Jul 16, 2018
42d3fb8
Take GasMeter in vm::execute
pepyakin Jul 16, 2018
75631f6
Use GasMeter throughout contract module for meter
pepyakin Jul 16, 2018
c2bc86d
gas module refactoring
pepyakin Jul 16, 2018
bf07b3c
Clean
pepyakin Jul 16, 2018
952112c
Add base call fee
pepyakin Jul 16, 2018
fa8991e
note about gas price should be taken from storage
pepyakin Jul 16, 2018
3e70be5
Add base fee for create
pepyakin Jul 16, 2018
87c5b12
Rename send → call
pepyakin Jul 16, 2018
f15ac41
Clean
pepyakin Jul 16, 2018
41f33b7
Take fee expressed in dots in gas
pepyakin Jul 16, 2018
cb6e995
Add Checked{Add,Sub,Mul,Div} to SimpleArithmetic
pepyakin Jul 16, 2018
8e5f297
Make Gas generic
pepyakin Jul 16, 2018
b16fec1
Store {call,create}_base_fee in storage
pepyakin Jul 16, 2018
6072034
Clean
pepyakin Jul 16, 2018
5bd0ee9
Rename buy_gas
pepyakin Jul 16, 2018
dadf9d8
Store gas_price in the storage
pepyakin Jul 16, 2018
6c93532
Remove unneeded comment.
pepyakin Jul 16, 2018
b84d090
Bail out if contract already has code.
pepyakin Jul 16, 2018
259a32f
Todos
pepyakin Jul 16, 2018
525df4b
Refund even if top-level contract fails.
pepyakin Jul 16, 2018
8562de6
Fix error msg
pepyakin Jul 16, 2018
4122f48
Fix caller issue
pepyakin Jul 16, 2018
f9497dd
Extract tests module
pepyakin Jul 16, 2018
7bf7759
Add max_depth var in storage
pepyakin Jul 16, 2018
de095a6
Remove left over gas_left
pepyakin Jul 16, 2018
338fe9f
Refactor exec
pepyakin Jul 16, 2018
4377497
Add test oog test.
pepyakin Jul 16, 2018
8ce5aed
set_free_balance_creating
pepyakin Jul 16, 2018
d8fa9e4
Docs and comments.
pepyakin Jul 17, 2018
a1ecfb0
Merge 'origin/master' into ser-contract-ioc
pepyakin Jul 17, 2018
91371c9
Update storage roots because of ContractFee move
pepyakin Jul 17, 2018
4dfc7dc
Rebuild binaries.
pepyakin Jul 17, 2018
2348c18
Simplify vm code.
pepyakin Jul 17, 2018
5873335
Wrapping.
pepyakin Jul 17, 2018
62b498d
Refactor a bit.
pepyakin Jul 17, 2018
895386d
Typo
pepyakin Jul 17, 2018
3e92676
UpdateBalanceOutcome enum
pepyakin Jul 17, 2018
ee97b9e
Style grumbles.
pepyakin Jul 17, 2018
34189ee
Merge 'origin/master' into ser-contract-ioc
pepyakin Jul 17, 2018
a18292a
Rebuild binaries.
pepyakin Jul 17, 2018
81e6eb7
Always consume the given amount of gas.
pepyakin Jul 17, 2018
9a52a44
[skip ci] endownment → endowment
pepyakin Jul 18, 2018
d91dfbe
Rename `AccountId` generic in on_account_kill
pepyakin Jul 23, 2018
ee83701
Merge branch 'master' into ser-contract-ioc
pepyakin Jul 24, 2018
f570351
Fix Cargo.lock
pepyakin Jul 24, 2018
4de767b
Refine docs for gas meter.
pepyakin Jul 24, 2018
58878a8
[skip ci] Add comments for gas module
pepyakin Jul 24, 2018
7a712e1
Merge branch 'master' into ser-contract-ioc
pepyakin Jul 24, 2018
eeebaba
Directly assign to `return_data` at declaration
pepyakin Jul 25, 2018
595e534
Use slices instead of vecs to pass the input data
pepyakin Jul 25, 2018
a846bb1
Add todo about passing return data without copy
pepyakin Jul 25, 2018
3afe59a
Use checked_add instead of add with overflow
pepyakin Jul 25, 2018
dae4d40
Use return_data directly.
pepyakin Jul 25, 2018
9e13c68
Rebuild binaries.
pepyakin Jul 25, 2018
d6c6250
Merge 'origin/master' into ser-contract-ioc
pepyakin Jul 27, 2018
af99a9d
Rebuild binaries.
pepyakin Jul 27, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fixup! Clean unrelevant comments
  • Loading branch information
pepyakin committed Jul 15, 2018
commit 3ab381c26b74ae8fa4eaeed9a2132538a84b3bbf
3 changes: 0 additions & 3 deletions substrate/runtime/contract/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -213,9 +213,6 @@ impl<T: Trait> Module<T> {
ctor_code: Vec<u8>,
data: Vec<u8>,
) -> Result {
// TODO: an additional fee, based upon gaslimit/gasprice.
// This fee should be taken in any way and not reverted.

let aux = aux.ref_into();

// Pay for the gas upfront.
Expand Down