PIVX (+testnet): Bump backend 3.1.1 -> 4.0.0 (#340)

* PIVX: bump to 4.0.0

* PIVX: remove AccCheckpoint in block version 7

ref https://github.com/PIVX-Project/PIVX/pull/1022

* PIVX: Test block v7 in pivxparser_test
pull/345/head
random.zebra 2020-01-03 12:45:40 +01:00 committed by Martin
parent 1ed7b3f2d9
commit b7a430574f
5 changed files with 17 additions and 8 deletions

View File

@ -98,8 +98,8 @@ func (p *PivXParser) ParseBlock(b []byte) (*bchain.Block, error) {
return nil, errors.Annotatef(err, "Deserialize")
}
if h.Version > 3 {
// Skip past AccumulatorCheckpoint which was added in pivx block version 4
if h.Version > 3 && h.Version < 7 {
// Skip past AccumulatorCheckpoint (block version 4, 5 and 6)
r.Seek(32, io.SeekCurrent)
}

View File

@ -414,6 +414,14 @@ var testParseBlockTxs = map[int]testBlock{
"baab318237b55f2dbb1ede2c65f7da9bf2c51c0e9a63903b3376f559fe999960",
},
},
1384217: {
size: 430,
time: 1577435460,
txs: []string{
"9c64e40fb27da7c7f826076d0f073968ce36188e827f5a7b2924974369bf9433",
"0c5b5b1b9c491a5a7ec9caab204e14f72383460b887c5342d296ae0a7451c09e",
},
},
}
func helperLoadBlock(t *testing.T, height int) []byte {

View File

@ -0,0 +1 @@
070000001f2ff47c56d8649a8901b22d65c19f73033e3cd1b2c28fd3e62f1aea53e39ea67ebf7cf103af62f05fcf8ef42c9149b520a2271e479a248aa1fddf72b70d750644c1055ed830391b000000000201000000010000000000000000000000000000000000000000000000000000000000000000ffffffff0703191f1502a206ffffffff010000000000000000000000000001000000011586257a85a8e9eba7b07bca8afec8084651c2dba2fe46ce02a622236b0822d001000000484730440220696ea3fd8b822f9f7d7abc92f9f1bfece2302db1d3195acd4d583829ec1c33be022077314512cb83a1f813572bae6c97869e92457635c4cd140b9cdead1112ac8c4e01ffffffff03000000000000000000001c59791b00000023210202b9346fdc655b1a2ccc517ce53058ec358f6509f1b24fadefbc052a9635fcccac00a3e111000000001976a9140aa851a9b4ff7f2166019e439a52b323e8c985a988ac00000000473045022100bf0c3deeb982927e4c74e3a3cfdbb4100a630d8d7d6b5969f3c434ecd9e2ff5b02203103857038500452a006efe0126a6ec0855b4219e3e0d4dc3c6fa754d308b9e0

View File

@ -22,10 +22,10 @@
"package_name": "backend-pivx",
"package_revision": "satoshilabs-1",
"system_user": "pivx",
"version": "3.1.1",
"binary_url": "https://github.com/PIVX-Project/PIVX/releases/download/v3.1.1/pivx-3.1.1-x86_64-linux-gnu.tar.gz",
"version": "4.0.0",
"binary_url": "https://github.com/PIVX-Project/PIVX/releases/download/v4.0.0/pivx-4.0.0-x86_64-linux-gnu.tar.gz",
"verification_type": "sha256",
"verification_source": "aac5b13beb9ff96b0ce62d2258d54166c756c8336672a67c7aae6b73a76b0c03",
"verification_source": "6cb1f608ec0e106ea6bbb455ec8b85c7cad05ca52ab43011d3db80557816b79e",
"extract_command": "tar -C backend --strip 1 -xf",
"exclude_files": [
"bin/pivx-qt"

View File

@ -22,10 +22,10 @@
"package_name": "backend-pivx",
"package_revision": "satoshilabs-1",
"system_user": "pivx",
"version": "3.1.1",
"binary_url": "https://github.com/PIVX-Project/PIVX/releases/download/v3.1.1/pivx-3.1.1-x86_64-linux-gnu.tar.gz",
"version": "4.0.0",
"binary_url": "https://github.com/PIVX-Project/PIVX/releases/download/v4.0.0/pivx-4.0.0-x86_64-linux-gnu.tar.gz",
"verification_type": "sha256",
"verification_source": "aac5b13beb9ff96b0ce62d2258d54166c756c8336672a67c7aae6b73a76b0c03",
"verification_source": "6cb1f608ec0e106ea6bbb455ec8b85c7cad05ca52ab43011d3db80557816b79e",
"extract_command": "tar -C backend --strip 1 -xf",
"exclude_files": [
"bin/pivx-qt"