Commit Graph

9 Commits

Author SHA1 Message Date
Grégoire Henry
370112f9b8 Makefile: simplify the compilation process.
This patch is co-authored with: cagdas.bozman@ocamlpro.com

With this patch the economic protocol is now compiled as as
"functor-pack", parameterized over the environment. This will ease the
protocol reusability outside of the tezos source tree (e.g. for a
michelson Web IDE) and will allow proper unit testing of the economic
protocol.

This functorization allows to break the dependency of the
'tezos-protocol-compiler' on various '.mli' of the node, and hence
we don't need anymore the unusual compilation schema:

  a.mli -> b.mli -> b.ml -> a.ml

where 'A' is linked after 'B' but 'a.mli' should still be compiled
before 'b.mli'. This will simplify a switch to 'ocp-build' or 'jbuiler'.
2017-10-11 13:44:09 +00:00
Grégoire Henry
2bc63854a8 Shell: Liveness of operations
Operations now include a block hash in their header. Such an operation
could only be included in a successor of this block.

Furthermore, when validating a block, the economic protocol now
returns---together with the context---an integer `max_operations_ttl`.
Then, when validating a successor, the shell will fail if it contains
an operation whose header's block hash is not one the
`max_operations_ttl` predecessors of the block.

As a bonus, the shell is now able to detect and forbid replayed
operations. Then, we might decide to remove some replay
detection-mechanism that we previously implemented in the economic
protocol.
2017-06-12 11:07:37 +02:00
Grégoire Henry
4bbc97aeb6 Shell: rework the preapply RPC
It now takes a `proto_header` in parameter, and it returns a full
`shell_header`. This prepares the inclusion of the context's hash in the
`shell_header`.
2017-06-12 11:07:35 +02:00
Grégoire Henry
f96ecbf667 Test: inject operation and block atomically 2017-06-12 11:05:46 +02:00
Benjamin Canou
90f87bec4a Alpha: update bootstrap parameters. 2017-06-01 01:53:54 +02:00
Grégoire Henry
f805507702 Shell: move level in th shell part of block. 2017-04-12 12:41:32 +02:00
Grégoire Henry
e276b0566e Alpha: minor changes in unit tests 2017-04-12 12:39:08 +02:00
Cagdas Bozman
c1e2d8eb25 Proto/Alpha: fix endorsement test 2017-04-10 18:31:37 +02:00
Cagdas Bozman
54027a701b Proto/Alpha: some unit tests for 'endorsement' 2017-04-10 18:31:37 +02:00