From 460ec8bbf9004a3d920b7ebe619caa2d7cf7d847 Mon Sep 17 00:00:00 2001 From: CryptoTeller Date: Sat, 1 Jul 2023 21:02:50 -0500 Subject: [PATCH 1/9] Update coins.py add Maza --- electrumx/lib/coins.py | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/electrumx/lib/coins.py b/electrumx/lib/coins.py index 2edf706bf..a4fa54ae4 100644 --- a/electrumx/lib/coins.py +++ b/electrumx/lib/coins.py @@ -546,7 +546,21 @@ def block_header(cls, block, height): deserializer = cls.DESERIALIZER(block) return deserializer.read_header(cls.BASIC_HEADER_SIZE) - +class Mazacoin(Coin): + NAME = "Mazacoin" + SHORTNAME = "MAZA" + NET = "mainnet" + P2PKH_VERBYTE = bytes.fromhex("1c") + P2SH_VERBYTES = bytes.fromhex("05") + WIF_BYTE = bytes.fromhex("b0") + GENESIS_HASH = ('00000c7c73d8ce604178dae13f0fc6ec0be3275614366d44b1b4b5c6e238c60c') + DESERIALIZER = lib_tx.DeserializerSegWit + TX_COUNT = 1 + TX_COUNT_HEIGHT = 1 + TX_PER_BLOCK = 1 + RPC_PORT = 12832 + REORG_LIMIT = 5000 + class Verge(Coin): NAME = "Verge" SHORTNAME = "XVG" From 801e2ee3a1f0f1a84c84bbfb9a3cd8fc4e0fa031 Mon Sep 17 00:00:00 2001 From: CryptoTeller Date: Sat, 8 Jul 2023 13:16:52 -0500 Subject: [PATCH 2/9] Update coins.py --- electrumx/lib/coins.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/electrumx/lib/coins.py b/electrumx/lib/coins.py index a4fa54ae4..716f86368 100644 --- a/electrumx/lib/coins.py +++ b/electrumx/lib/coins.py @@ -560,7 +560,8 @@ class Mazacoin(Coin): TX_PER_BLOCK = 1 RPC_PORT = 12832 REORG_LIMIT = 5000 - + + class Verge(Coin): NAME = "Verge" SHORTNAME = "XVG" From 9e8321a94629a27ef7f82ffc2317bcbd77374e3d Mon Sep 17 00:00:00 2001 From: CryptoTeller Date: Sat, 8 Jul 2023 13:42:27 -0500 Subject: [PATCH 3/9] Create maza_mainnet_2100000.json --- tests/blocks/maza_mainnet_2100000.json | 28 ++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 tests/blocks/maza_mainnet_2100000.json diff --git a/tests/blocks/maza_mainnet_2100000.json b/tests/blocks/maza_mainnet_2100000.json new file mode 100644 index 000000000..33c962701 --- /dev/null +++ b/tests/blocks/maza_mainnet_2100000.json @@ -0,0 +1,28 @@ +{ + "bits": "1a028d42", + "chainwork": "000000000000000000000000000000000000000000000b075065e398af20b7e1", + "confirmations": 705855, + "difficulty": 6574589.201717354, + "hash": "00000000000000d16ed3139efea523237156543b7e24e97c7ae2b830440ca95e", + "height": 2100000, + "hivedifficulty": 1, + "mediantime": 1643172763, + "merkleroot": "8040681758c5b12d628dcbd3010c9f760451f6217e4d755443895ccf4827e51e", + "nextblockhash": "000000000000023a40d41162e584a00f2ddd718d1b1da4e76e629a860a32776a", + "nonce": 3933155685, + "previousblockhash": "000000000000018f97be64b6f61eb88b4a30aac4687b95a1944a43b5994a98c2", + "size": 1331, + "strippedsize": 1331, + "time": 1643174337, + "tx": [ + "3e92a01a1c3ea2bb525bf00819cfba68ab984d4158395721fbbbe3f9b80c8fff", + "6fc2486917f575c8f6a92a03e832af3cb30b3b4269ead7d48a5c8e0c75ba5499", + "5183544bdb1564b3d64b6c1bb5a5ae7c43ac307075b77a00a0597a01a9dc036e" + ], + "type": "pow", + "version": 1, + "versionHex": "00000001", + "weight": 5324, + "block": "00000000000000d16ed3139efea523237156543b7e24e97c7ae2b830440ca95e" + } + From 5c5f2e9e4efe65dc329ffae2a91cad1b5970f4a7 Mon Sep 17 00:00:00 2001 From: CryptoTeller Date: Sat, 8 Jul 2023 13:45:56 -0500 Subject: [PATCH 4/9] add Maza Support --- tests/blocks/maza_mainnet_2100000.json | 1 - 1 file changed, 1 deletion(-) diff --git a/tests/blocks/maza_mainnet_2100000.json b/tests/blocks/maza_mainnet_2100000.json index 33c962701..1bf898c2c 100644 --- a/tests/blocks/maza_mainnet_2100000.json +++ b/tests/blocks/maza_mainnet_2100000.json @@ -25,4 +25,3 @@ "weight": 5324, "block": "00000000000000d16ed3139efea523237156543b7e24e97c7ae2b830440ca95e" } - From 936ea230c7bfdf323622f2c38d34d4ad71f2aa3b Mon Sep 17 00:00:00 2001 From: CryptoTeller Date: Sat, 8 Jul 2023 13:51:51 -0500 Subject: [PATCH 5/9] add Maza support --- tests/blocks/maza_mainnet_2100000.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/blocks/maza_mainnet_2100000.json b/tests/blocks/maza_mainnet_2100000.json index 1bf898c2c..5f97d3cb2 100644 --- a/tests/blocks/maza_mainnet_2100000.json +++ b/tests/blocks/maza_mainnet_2100000.json @@ -23,5 +23,5 @@ "version": 1, "versionHex": "00000001", "weight": 5324, - "block": "00000000000000d16ed3139efea523237156543b7e24e97c7ae2b830440ca95e" + "block": "00000020c2984a99b5434a94a1957b68c4aa304a8bb81ef6b664be978f010000000000001ee52748cf5c894354754d7e21f65104769f0c01d3cb8d622db1c55817684080c1d9f061428d021a65316fea0301000000010000000000000000000000000000000000000000000000000000000000000000ffffffff4c03200b2004b6d7f06108fabe6d6ddc6560991b7e1ec2a941c53d732bbc2a12b79142fca62e80cd11db3e8401718d010000000000000017ffffffff7c01000d2f6e6f64655374726174756d2f00000000020000000000000000266a24aa21a9edf668f5394fce054bf89f95bdd8ff33d49c446fa364506e57543e8fd25f22121adece1dd2050000001976a914ceabfbe35f8690ef643bff4d5ff54925f9e0f09988ac000000000100000001bfb48498f87a922eda969b85b0544a7d72894a6ea390adc30bbeff814ad7c496000000006b483045022100c6e241a9bffef348819db4f45347193ae77693a3a8a2c83a0a9e0717b1af06a402206d45139c0d26f3e91c3af9ffd6ab2fba3a0b8a2c4645002131e193be0b90381501210203f40a91b3d0827104b468c0d7b757d0c3052ed5ee415b11c497b4dd5708e69bffffffff02b8e4270e000000001976a91479158fde0146bb6e16bade570444d937d7f5c3d288aca0c3f5c3050000001976a91422820e2d7a86ae306a8a38f256315fe940ae665d88ac00000000010000000507cd1229f3e9168bbd762c4cfecf00fdc40341ade73c7f5bb97999d80edc14d8000000006a473044022032e304f9b0f06e1acb25f0de2b2947fa1f85653bdeed4638e6274fd3e3ccb3e602200cd02e6bcfa9985f88ea81ce454ba7926a663e49140a429ab6f8a2c417ea87ff012103198e982c81eb3da518863ff8705ad647019560520cc847614a94783e307be505feffffff1f42b86526a8b49f704b8b8b1c74922a10681d18746d1507be65051f0410b152000000006b483045022100dba729ef9e488f4ae30a856d9a443a5412892f613c6d244120d6778aab897342022051b8283359bc8ca1bf4f4f7eb26fcbfe5e81de1965f21c282666f5fcd62586db012103198e982c81eb3da518863ff8705ad647019560520cc847614a94783e307be505feffffff3bebe9c19ff2f65d9b78d352098a1cc00bf362d1abbbe8272a6ea93489127b57010000006a47304402200f4ee47a31485e8b07b81f41092b088ddd07d2035b3b742fa2fc5ee977f48d2c02203dfb05c55fae692c15fdc65888ed23bc7abd93c9f7715b4bde1f6ace1ab515db012103198e982c81eb3da518863ff8705ad647019560520cc847614a94783e307be505feffffff72f53b8e7d8226c283be6b6d3003d90e7b92fbf4a01d67c3ec9c98cc4fb4f747000000006b483045022100c5fc1972935f748a64482936933ba1851b1833d56dc9af4151e5dd440af27a5602202861941289abb968535425d2a6335586edf53139a27b56dfeb57c0fb57a38e1b012103198e982c81eb3da518863ff8705ad647019560520cc847614a94783e307be505feffffff8abe153a93be42f4328bdc64a52118252b2d0f108bba6b65bb13b9d481efc2a8000000006b483045022100edd071a4bd81a47ccd38d48c930568f6431edd4f51e845cd27cd2f807522122702205582972f281566ec22f2dafc6a59120f961797e9d148a340a58d5eaa91f92e1c012103198e982c81eb3da518863ff8705ad647019560520cc847614a94783e307be505feffffff029a2f58e6030000001976a9149d029373f0427b70044a34d038fdbf123dcb898b88ac306f3c34190000001976a914a78ec10fa0653a7bbbe6a48f821f12361c9c2b3088ac1f0b2000" } From 0c6a8d6e70bf5ecd1277a0c36b7b2ce7ce76cc36 Mon Sep 17 00:00:00 2001 From: CryptoTeller Date: Sat, 8 Jul 2023 13:59:25 -0500 Subject: [PATCH 6/9] add Maza support --- electrumx/lib/coins.py | 1 + 1 file changed, 1 insertion(+) diff --git a/electrumx/lib/coins.py b/electrumx/lib/coins.py index 716f86368..08c84bcec 100644 --- a/electrumx/lib/coins.py +++ b/electrumx/lib/coins.py @@ -546,6 +546,7 @@ def block_header(cls, block, height): deserializer = cls.DESERIALIZER(block) return deserializer.read_header(cls.BASIC_HEADER_SIZE) + class Mazacoin(Coin): NAME = "Mazacoin" SHORTNAME = "MAZA" From 035d6c1c231ecd3cdab19c0bcf98e8a2380c4b19 Mon Sep 17 00:00:00 2001 From: CryptoTeller Date: Sat, 8 Jul 2023 14:01:02 -0500 Subject: [PATCH 7/9] add Maza support --- electrumx/lib/coins.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/electrumx/lib/coins.py b/electrumx/lib/coins.py index 08c84bcec..aaaf0d35e 100644 --- a/electrumx/lib/coins.py +++ b/electrumx/lib/coins.py @@ -560,8 +560,8 @@ class Mazacoin(Coin): TX_COUNT_HEIGHT = 1 TX_PER_BLOCK = 1 RPC_PORT = 12832 - REORG_LIMIT = 5000 - + REORG_LIMIT = 5000 + class Verge(Coin): NAME = "Verge" From 661ad545e1f0ce779c07fc8942b5c7e4cf78e3cb Mon Sep 17 00:00:00 2001 From: CryptoTeller Date: Sat, 8 Jul 2023 14:02:31 -0500 Subject: [PATCH 8/9] add Maza support --- electrumx/lib/coins.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/electrumx/lib/coins.py b/electrumx/lib/coins.py index aaaf0d35e..fe5f37d3d 100644 --- a/electrumx/lib/coins.py +++ b/electrumx/lib/coins.py @@ -561,7 +561,7 @@ class Mazacoin(Coin): TX_PER_BLOCK = 1 RPC_PORT = 12832 REORG_LIMIT = 5000 - + class Verge(Coin): NAME = "Verge" From 8133f4f622e02fc210715e573b510afb14abe758 Mon Sep 17 00:00:00 2001 From: CryptoTeller Date: Sat, 8 Jul 2023 21:52:29 -0500 Subject: [PATCH 9/9] Rename maza_mainnet_2100000.json to mazacoin_mainnet_2100000.json --- .../{maza_mainnet_2100000.json => mazacoin_mainnet_2100000.json} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename tests/blocks/{maza_mainnet_2100000.json => mazacoin_mainnet_2100000.json} (100%) diff --git a/tests/blocks/maza_mainnet_2100000.json b/tests/blocks/mazacoin_mainnet_2100000.json similarity index 100% rename from tests/blocks/maza_mainnet_2100000.json rename to tests/blocks/mazacoin_mainnet_2100000.json