aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Gopkg.lock26
-rw-r--r--simulation/validator.go8
2 files changed, 9 insertions, 25 deletions
diff --git a/Gopkg.lock b/Gopkg.lock
index f6ae37f..0969c2b 100644
--- a/Gopkg.lock
+++ b/Gopkg.lock
@@ -2,6 +2,14 @@
[[projects]]
+ branch = "master"
+ digest = "1:ae0b29e6e7c0856b94ca0060f6328b1bd714f07c7d51b5b0cbe55075f39da4ce"
+ name = "github.com/cobinhood/decimal"
+ packages = ["."]
+ pruneopts = "UT"
+ revision = "9ca7f51822d222ae4e246f070f9aad863599bd1a"
+
+[[projects]]
digest = "1:a2c1d0e43bd3baaa071d1b9ed72c27d78169b2b269f71c105ac4ba34b1be4a39"
name = "github.com/davecgh/go-spew"
packages = ["spew"]
@@ -81,27 +89,11 @@
analyzer-name = "dep"
analyzer-version = 1
input-imports = [
- "github.com/davecgh/go-spew/spew",
- "github.com/golang/snappy",
- "github.com/naoina/go-stringutil",
+ "github.com/cobinhood/decimal",
"github.com/naoina/toml",
- "github.com/naoina/toml/ast",
- "github.com/pmezard/go-difflib/difflib",
- "github.com/stretchr/testify/assert",
- "github.com/stretchr/testify/require",
"github.com/stretchr/testify/suite",
"github.com/syndtr/goleveldb/leveldb",
- "github.com/syndtr/goleveldb/leveldb/cache",
- "github.com/syndtr/goleveldb/leveldb/comparer",
- "github.com/syndtr/goleveldb/leveldb/errors",
- "github.com/syndtr/goleveldb/leveldb/filter",
- "github.com/syndtr/goleveldb/leveldb/iterator",
- "github.com/syndtr/goleveldb/leveldb/journal",
- "github.com/syndtr/goleveldb/leveldb/memdb",
"github.com/syndtr/goleveldb/leveldb/opt",
- "github.com/syndtr/goleveldb/leveldb/storage",
- "github.com/syndtr/goleveldb/leveldb/table",
- "github.com/syndtr/goleveldb/leveldb/util",
]
solver-name = "gps-cdcl"
solver-version = 1
diff --git a/simulation/validator.go b/simulation/validator.go
index fb8afed..97412b1 100644
--- a/simulation/validator.go
+++ b/simulation/validator.go
@@ -123,12 +123,6 @@ func (v *Validator) MsgServer() {
}
}
-func (v *Validator) createBlockTimestamps() map[types.ValidatorID]time.Time {
- timestamps := make(map[types.ValidatorID]time.Time)
- timestamps[v.GetID()] = time.Now()
- return timestamps
-}
-
// BroadcastGenesisBlock broadcasts genesis block to all peers.
func (v *Validator) BroadcastGenesisBlock() {
// Wait until all peer joined the network.
@@ -143,7 +137,6 @@ func (v *Validator) BroadcastGenesisBlock() {
ParentHash: hash,
Hash: hash,
Height: 0,
- Timestamps: v.createBlockTimestamps(),
Acks: map[common.Hash]struct{}{},
}
v.genesis = b
@@ -177,7 +170,6 @@ ProposingBlockLoop:
ParentHash: v.current.Hash,
Hash: common.NewRandomHash(),
Height: v.current.Height + 1.,
- Timestamps: v.createBlockTimestamps(),
Acks: map[common.Hash]struct{}{},
}
v.current = block