aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJimmy Hu <jimmy.hu@dexon.org>2019-01-05 18:04:26 +0800
committerWei-Ning Huang <w@dexon.org>2019-01-14 15:26:26 +0800
commit9b93d9105164b5c64932b9e563c75bdf02ef6bd4 (patch)
treea7d53d30cd43e515a4e106c93affc8dfd2706fea
parentc8ae74af4300e1e3a817dd08fcaebfc8c9f1d661 (diff)
downloaddexon-9b93d9105164b5c64932b9e563c75bdf02ef6bd4.tar
dexon-9b93d9105164b5c64932b9e563c75bdf02ef6bd4.tar.gz
dexon-9b93d9105164b5c64932b9e563c75bdf02ef6bd4.tar.bz2
dexon-9b93d9105164b5c64932b9e563c75bdf02ef6bd4.tar.lz
dexon-9b93d9105164b5c64932b9e563c75bdf02ef6bd4.tar.xz
dexon-9b93d9105164b5c64932b9e563c75bdf02ef6bd4.tar.zst
dexon-9b93d9105164b5c64932b9e563c75bdf02ef6bd4.zip
vendor: sync to latest core and fix conflict
-rw-r--r--dex/governance.go9
-rw-r--r--vendor/github.com/dexon-foundation/dexon-consensus/core/configuration-chain.go3
-rw-r--r--vendor/github.com/dexon-foundation/dexon-consensus/core/interfaces.go6
-rw-r--r--vendor/vendor.json42
4 files changed, 37 insertions, 23 deletions
diff --git a/dex/governance.go b/dex/governance.go
index bcc2cca51..199bcdc87 100644
--- a/dex/governance.go
+++ b/dex/governance.go
@@ -27,6 +27,7 @@ import (
dexCore "github.com/dexon-foundation/dexon-consensus/core"
coreCrypto "github.com/dexon-foundation/dexon-consensus/core/crypto"
coreEcdsa "github.com/dexon-foundation/dexon-consensus/core/crypto/ecdsa"
+ coreTypes "github.com/dexon-foundation/dexon-consensus/core/types"
dkgTypes "github.com/dexon-foundation/dexon-consensus/core/types/dkg"
"github.com/dexon-foundation/dexon/common"
@@ -291,3 +292,11 @@ func (d *DexconGovernance) DKGSet(round uint64) (map[string]struct{}, error) {
}
return r, nil
}
+
+func (d *DexconGovernance) ReportForkVote(vote1, vote2 *coreTypes.Vote) {
+ // TODO: finish this.
+}
+
+func (d *DexconGovernance) ReportForkBlock(block1, block2 *coreTypes.Block) {
+ // TODO: finish this.
+}
diff --git a/vendor/github.com/dexon-foundation/dexon-consensus/core/configuration-chain.go b/vendor/github.com/dexon-foundation/dexon-consensus/core/configuration-chain.go
index 4938ba0e6..fbd691f73 100644
--- a/vendor/github.com/dexon-foundation/dexon-consensus/core/configuration-chain.go
+++ b/vendor/github.com/dexon-foundation/dexon-consensus/core/configuration-chain.go
@@ -91,8 +91,7 @@ func (cc *configurationChain) registerDKG(round uint64, threshold int) {
defer cc.dkgLock.Unlock()
if cc.dkg != nil {
cc.logger.Error("Previous DKG is not finished")
- // TODO(mission): do we have to retry DKG initiation here?
- return
+ // TODO(mission): return here and fix CI failure.
}
dkgSet, err := cc.cache.GetDKGSet(round)
if err != nil {
diff --git a/vendor/github.com/dexon-foundation/dexon-consensus/core/interfaces.go b/vendor/github.com/dexon-foundation/dexon-consensus/core/interfaces.go
index 20770328c..aa87e38f7 100644
--- a/vendor/github.com/dexon-foundation/dexon-consensus/core/interfaces.go
+++ b/vendor/github.com/dexon-foundation/dexon-consensus/core/interfaces.go
@@ -144,6 +144,12 @@ type Governance interface {
// IsDKGFinal checks if DKG is final.
IsDKGFinal(round uint64) bool
+
+ // ReportForkVote reports a node for forking votes.
+ ReportForkVote(vote1, vote2 *types.Vote)
+
+ // ReportForkBlock reports a node for forking blocks.
+ ReportForkBlock(block1, block2 *types.Block)
}
// Ticker define the capability to tick by interval.
diff --git a/vendor/vendor.json b/vendor/vendor.json
index 02a9c2299..6ead45a1a 100644
--- a/vendor/vendor.json
+++ b/vendor/vendor.json
@@ -141,16 +141,16 @@
{
"checksumSHA1": "ZUuiRqS6PnoNIvBmLStVQiyhkOM=",
"path": "github.com/dexon-foundation/dexon-consensus/common",
- "revision": "65f14ef166d7fd3ea30f50366d55777b54fe305f",
- "revisionTime": "2019-01-04T16:16:15Z",
+ "revision": "af8c182a07f9bf3a7a17c938c87f4eef489bb903",
+ "revisionTime": "2019-01-05T09:58:34Z",
"version": "master",
"versionExact": "master"
},
{
- "checksumSHA1": "K0/Xw7IgS3JSHGt93LzW3Lrg2FI=",
+ "checksumSHA1": "aqhVp5CBDq52ytHUH3HatpWhTDQ=",
"path": "github.com/dexon-foundation/dexon-consensus/core",
- "revision": "65f14ef166d7fd3ea30f50366d55777b54fe305f",
- "revisionTime": "2019-01-04T16:16:15Z",
+ "revision": "af8c182a07f9bf3a7a17c938c87f4eef489bb903",
+ "revisionTime": "2019-01-05T09:58:34Z",
"version": "master",
"versionExact": "master"
},
@@ -165,64 +165,64 @@
{
"checksumSHA1": "tQSbYCu5P00lUhKsx3IbBZCuSLY=",
"path": "github.com/dexon-foundation/dexon-consensus/core/crypto",
- "revision": "65f14ef166d7fd3ea30f50366d55777b54fe305f",
- "revisionTime": "2019-01-04T16:16:15Z",
+ "revision": "af8c182a07f9bf3a7a17c938c87f4eef489bb903",
+ "revisionTime": "2019-01-05T09:58:34Z",
"version": "master",
"versionExact": "master"
},
{
"checksumSHA1": "W2P7pkuJ+26BpJg03K4Y0nB5obI=",
"path": "github.com/dexon-foundation/dexon-consensus/core/crypto/dkg",
- "revision": "65f14ef166d7fd3ea30f50366d55777b54fe305f",
- "revisionTime": "2019-01-04T16:16:15Z",
+ "revision": "af8c182a07f9bf3a7a17c938c87f4eef489bb903",
+ "revisionTime": "2019-01-05T09:58:34Z",
"version": "master",
"versionExact": "master"
},
{
"checksumSHA1": "6Pf6caC8LTNCI7IflFmglKYnxYo=",
"path": "github.com/dexon-foundation/dexon-consensus/core/crypto/ecdsa",
- "revision": "65f14ef166d7fd3ea30f50366d55777b54fe305f",
- "revisionTime": "2019-01-04T16:16:15Z",
+ "revision": "af8c182a07f9bf3a7a17c938c87f4eef489bb903",
+ "revisionTime": "2019-01-05T09:58:34Z",
"version": "master",
"versionExact": "master"
},
{
"checksumSHA1": "PJXR1OuWwVVYrdJMK3skPr1/8ls=",
"path": "github.com/dexon-foundation/dexon-consensus/core/db",
- "revision": "65f14ef166d7fd3ea30f50366d55777b54fe305f",
- "revisionTime": "2019-01-04T16:16:15Z",
+ "revision": "af8c182a07f9bf3a7a17c938c87f4eef489bb903",
+ "revisionTime": "2019-01-05T09:58:34Z",
"version": "master",
"versionExact": "master"
},
{
"checksumSHA1": "h674l/hugVujbZUy/NSeDmio3/U=",
"path": "github.com/dexon-foundation/dexon-consensus/core/syncer",
- "revision": "65f14ef166d7fd3ea30f50366d55777b54fe305f",
- "revisionTime": "2019-01-04T16:16:15Z",
+ "revision": "af8c182a07f9bf3a7a17c938c87f4eef489bb903",
+ "revisionTime": "2019-01-05T09:58:34Z",
"version": "master",
"versionExact": "master"
},
{
"checksumSHA1": "GRiBmU5T1LAoGHs5g1owGE1tNNo=",
"path": "github.com/dexon-foundation/dexon-consensus/core/types",
- "revision": "65f14ef166d7fd3ea30f50366d55777b54fe305f",
- "revisionTime": "2019-01-04T16:16:15Z",
+ "revision": "af8c182a07f9bf3a7a17c938c87f4eef489bb903",
+ "revisionTime": "2019-01-05T09:58:34Z",
"version": "master",
"versionExact": "master"
},
{
"checksumSHA1": "rmv8uxwrqMhJAeA3RPvwYP8mFro=",
"path": "github.com/dexon-foundation/dexon-consensus/core/types/dkg",
- "revision": "65f14ef166d7fd3ea30f50366d55777b54fe305f",
- "revisionTime": "2019-01-04T16:16:15Z",
+ "revision": "af8c182a07f9bf3a7a17c938c87f4eef489bb903",
+ "revisionTime": "2019-01-05T09:58:34Z",
"version": "master",
"versionExact": "master"
},
{
"checksumSHA1": "NCAEGRVPfM0jCKdrBN2yvEXkeIo=",
"path": "github.com/dexon-foundation/dexon-consensus/core/utils",
- "revision": "65f14ef166d7fd3ea30f50366d55777b54fe305f",
- "revisionTime": "2019-01-04T16:16:15Z",
+ "revision": "af8c182a07f9bf3a7a17c938c87f4eef489bb903",
+ "revisionTime": "2019-01-05T09:58:34Z",
"version": "master",
"versionExact": "master"
},