From c10eff1404293322e7a19da3a3580e2e8409c786 Mon Sep 17 00:00:00 2001 From: Mario Vega Date: Fri, 11 Mar 2022 11:16:12 -0600 Subject: [PATCH 01/56] Update links to the proper releases page Update links that point to the releases page from `https://github.com/ethereum/staking-deposit-cli/releases` to `https://github.com/ethereum/eth2.0-deposit-cli/releases` --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 45d732a2..e8ed83ef 100644 --- a/README.md +++ b/README.md @@ -94,7 +94,7 @@ On Unix-based systems, keystores and the `deposit_data*.json` have `440`/`-r--r- ##### Step 1. Installation -See [releases page](https://github.com/ethereum/staking-deposit-cli/releases) to download and decompress the corresponding binary files. +See [releases page](https://github.com/ethereum/eth2.0-deposit-cli/releases) to download and decompress the corresponding binary files. ##### Step 2. Create keys and `deposit_data-*.json` @@ -338,7 +338,7 @@ See [here](#successful-message) ##### Step 1. Installation -See [releases page](https://github.com/ethereum/staking-deposit-cli/releases) to download and decompress the corresponding binary files. +See [releases page](https://github.com/ethereum/eth2.0-deposit-cli/releases) to download and decompress the corresponding binary files. ##### Step 2. Create keys and `deposit_data-*.json` @@ -532,4 +532,4 @@ python3 -m pytest . If you are trying to **build the binary** on macos with an M1 Mac and you are using pyenv to manage your python version. You'll probably need to reinstall a given python version using: ``` env PYTHON_CONFIGURE_OPTS="--enable-framework" pyenv install 3.10.2 -``` \ No newline at end of file +``` From a76f187a678903f83a306b26413c2046b4f12cf9 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Wed, 16 Mar 2022 13:56:27 +0100 Subject: [PATCH 02/56] bump the versions on all the packages! --- build_configs/linux/requirements.txt | 73 ++++++----- build_configs/macos/requirements.txt | 73 ++++++----- build_configs/windows/requirements.txt | 77 ++++++------ requirements.txt | 140 +++++++++++---------- requirements_test.txt | 167 +++++++++++++------------ 5 files changed, 273 insertions(+), 257 deletions(-) diff --git a/build_configs/linux/requirements.txt b/build_configs/linux/requirements.txt index 28b6bb3c..bd943ea1 100644 --- a/build_configs/linux/requirements.txt +++ b/build_configs/linux/requirements.txt @@ -2,21 +2,21 @@ -r ../../requirements.txt # Build tools for binary distribution -pyinstaller==4.8 \ - --hash=sha256:15d9266d78dc757c103962826e62bce1513825078160be580534ead2ef53087c \ - --hash=sha256:44783d58ac4cb0a74a4f2180da4dacbe6a7a013a62b3aa10be6082252e296954 \ - --hash=sha256:4c848720a65a5bd41249bc804d1bd3dd089bb56aef7f1c5e11f774f11e649443 \ - --hash=sha256:53ed05214dd67624756fe4e82e861857921a79d0392debf8c9f5bb0ba5a479b6 \ - --hash=sha256:5c2fd5f18c0397f3d9160446035556afc7f6446fd88048887fdf46eadf85c5ec \ - --hash=sha256:6f5cdc39fbdec7b2e0c46cc0f5bd0071bb85e592e324bf4e15375c5ff19e55fc \ - --hash=sha256:7ae868bbcc502832a2c802c84a1dbb9f48b44445c50144c29bfcd7b760140e13 \ - --hash=sha256:9fbb05f5f67862005234da8c7eac69ef87e086f90e345749260051b031774c52 \ - --hash=sha256:b0b3a31aa60292469f9595f298e2c147cba29c30edcd92a38fdce27727809625 \ - --hash=sha256:b720853a00bd9547b7d6403d85f23b7f7e451e41bc907673d9fc7f8d9d274594 \ - --hash=sha256:f00e1296abac71f3b5bb9fdc2e0d4c079201d62faeeeb894ccadd0616179fee3 -setuptools==49.2.0 \ - --hash=sha256:272c7f48f5cddc5af5901f4265274c421c7eede5c8bc454ac2903d3f8fc365e9 \ - --hash=sha256:afe9e81fee0270d3f60d52608549cc8ec4c46dada8c95640c1a00160f577acf2 +pyinstaller==4.10 \ + --hash=sha256:05c21117b84199272ebd355b556af4714f6e79245e1c435d6f16653786d7d17e \ + --hash=sha256:0dcaf6557cdb2da763c46e06e95a94a7634ab03fb09d91bc77988b01ee05c907 \ + --hash=sha256:15557cd1a79d182967f0a5040750e6902e13ebd6cab41e3ed84d7b28a306357b \ + --hash=sha256:581620bdcd32f01e89b13231256b807bb090e7eadf40c81c864ec402afa4758a \ + --hash=sha256:70c71e827f4b34602cbc7a0947a067b662c1cbdc4db51832e13b97cca3c54dd7 \ + --hash=sha256:714c4dcc319a41416744d1e30c6317405dfaed80d2adc45f8bfa70dc7367e664 \ + --hash=sha256:7749c868d2e2dc84df7d6f65437226183c8a366f3a99bb2737785625c3a3cca1 \ + --hash=sha256:7d94518ba1f8e9a8577345312276891ad7d6cd9785e453e9951b35647e2c7078 \ + --hash=sha256:cfed0b3a43e73550a43a094610328109564710b9514afa093ef7199d072cae87 \ + --hash=sha256:d4f79c0a774451f12baca4e476376418f011fa3039dde8fd172ea2aa8ff67bad \ + --hash=sha256:f2166ff2cd95eefb0d377ae8d1071f186fa25edd410ede65b376162d5ec41909 +setuptools==60.9.3 \ + --hash=sha256:2347b2b432c891a863acadca2da9ac101eae6169b1d3dfee2ec605ecd50dbfe5 \ + --hash=sha256:e4f30b9f84e5ab3decf945113119649fec09c1fc3507c6ebffec75646c56e62b cffi==1.15.0 \ --hash=sha256:00c878c90cb53ccfaae6b8bc18ad05d2036553e6d9d1d9dbcf323bbe83854ca3 \ --hash=sha256:0104fb5ae2391d46a4cb082abdd5c69ea4eab79d8d44eaaf79f1b1fd806ee4c2 \ @@ -68,25 +68,24 @@ cffi==1.15.0 \ --hash=sha256:f6f824dc3bce0edab5f427efcfb1d63ee75b6fcb7282900ccaf925be84efb0fc \ --hash=sha256:fd8a250edc26254fe5b33be00402e6d287f562b6a5b2152dec302fa15bb3e997 \ --hash=sha256:ffaa5c925128e29efbde7301d8ecaf35c8c60ffbcd6a1ffd3a552177c8e5e796 -pycparser==2.20 \ - --hash=sha256:2d475327684562c3a96cc71adf7dc8c4f0565175cf86b6d7a404ff4c771f15f0 \ - --hash=sha256:7582ad22678f0fcd81102833f60ef8d0e57288b6b5fb00323d101be910e35705 -altgraph==0.17 \ - --hash=sha256:1f05a47122542f97028caf78775a095fbe6a2699b5089de8477eb583167d69aa \ - --hash=sha256:c623e5f3408ca61d4016f23a681b9adb100802ca3e3da5e718915a9e4052cebe -macholib==1.14 \ - --hash=sha256:0c436bc847e7b1d9bda0560351bf76d7caf930fb585a828d13608839ef42c432 \ - --hash=sha256:c500f02867515e6c60a27875b408920d18332ddf96b4035ef03beddd782d4281 -pyinstaller-hooks-contrib==2022.0 \ - --hash=sha256:29f0bd8fbb2ff6f2df60a0c147e5b5ad65ae5c1a982d90641a5f712de03fa161 \ - --hash=sha256:61b667f51b2525377fae30793f38fd9752a08032c72b209effabf707c840cc38 -importlib-metadata==3.10.0 \ - --hash=sha256:c9db46394197244adf2f0b08ec5bc3cf16757e9590b02af1fca085c16c0d600a \ - --hash=sha256:d2d46ef77ffc85cbf7dac7e81dd663fde71c45326131bea8033b9bad42268ebe -zipp==3.4.1 \ - --hash=sha256:3607921face881ba3e026887d8150cca609d517579abe052ac81fc5aeffdbd76 \ - --hash=sha256:51cb66cc54621609dd593d1787f286ee42a5c0adbb4b29abea5a63edc3e03098 -typing-extensions==3.7.4.3 \ - --hash=sha256:7cb407020f00f7bfc3cb3e7881628838e69d8f3fcab2f64742a5e76b2f841918 \ - --hash=sha256:99d4073b617d30288f569d3f13d2bd7548c3a7e4c8de87db09a9d29bb3a4a60c \ - --hash=sha256:dafc7639cde7f1b6e1acc0f457842a83e722ccca8eef5270af2d74792619a89f +pycparser==2.21 \ + --hash=sha256:8ee45429555515e1f6b185e78100aea234072576aa43ab53aefcae078162fca9 \ + --hash=sha256:e644fdec12f7872f86c58ff790da456218b10f863970249516d60a5eaca77206 +altgraph==0.17.2 \ + --hash=sha256:743628f2ac6a7c26f5d9223c91ed8ecbba535f506f4b6f558885a8a56a105857 \ + --hash=sha256:ebf2269361b47d97b3b88e696439f6e4cbc607c17c51feb1754f90fb79839158 +macholib==1.15.2 \ + --hash=sha256:1542c41da3600509f91c165cb897e7e54c0e74008bd8da5da7ebbee519d593d2 \ + --hash=sha256:885613dd02d3e26dbd2b541eb4cc4ce611b841f827c0958ab98656e478b9e6f6 +pyinstaller-hooks-contrib==2022.2 \ + --hash=sha256:7605e440ccb55904cb2a87d72e83642ef176fb7030c77e52ac4d9679bb3d1537 \ + --hash=sha256:ab1d14fe053016fff7b0c6aea51d980bac6d02114b04063b46ef7dac70c70e1e +importlib-metadata==4.11.3 \ + --hash=sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6 \ + --hash=sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539 +zipp==3.7.0 \ + --hash=sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d \ + --hash=sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375 +typing-extensions==4.1.1 \ + --hash=sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42 \ + --hash=sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2 diff --git a/build_configs/macos/requirements.txt b/build_configs/macos/requirements.txt index 28b6bb3c..bd943ea1 100644 --- a/build_configs/macos/requirements.txt +++ b/build_configs/macos/requirements.txt @@ -2,21 +2,21 @@ -r ../../requirements.txt # Build tools for binary distribution -pyinstaller==4.8 \ - --hash=sha256:15d9266d78dc757c103962826e62bce1513825078160be580534ead2ef53087c \ - --hash=sha256:44783d58ac4cb0a74a4f2180da4dacbe6a7a013a62b3aa10be6082252e296954 \ - --hash=sha256:4c848720a65a5bd41249bc804d1bd3dd089bb56aef7f1c5e11f774f11e649443 \ - --hash=sha256:53ed05214dd67624756fe4e82e861857921a79d0392debf8c9f5bb0ba5a479b6 \ - --hash=sha256:5c2fd5f18c0397f3d9160446035556afc7f6446fd88048887fdf46eadf85c5ec \ - --hash=sha256:6f5cdc39fbdec7b2e0c46cc0f5bd0071bb85e592e324bf4e15375c5ff19e55fc \ - --hash=sha256:7ae868bbcc502832a2c802c84a1dbb9f48b44445c50144c29bfcd7b760140e13 \ - --hash=sha256:9fbb05f5f67862005234da8c7eac69ef87e086f90e345749260051b031774c52 \ - --hash=sha256:b0b3a31aa60292469f9595f298e2c147cba29c30edcd92a38fdce27727809625 \ - --hash=sha256:b720853a00bd9547b7d6403d85f23b7f7e451e41bc907673d9fc7f8d9d274594 \ - --hash=sha256:f00e1296abac71f3b5bb9fdc2e0d4c079201d62faeeeb894ccadd0616179fee3 -setuptools==49.2.0 \ - --hash=sha256:272c7f48f5cddc5af5901f4265274c421c7eede5c8bc454ac2903d3f8fc365e9 \ - --hash=sha256:afe9e81fee0270d3f60d52608549cc8ec4c46dada8c95640c1a00160f577acf2 +pyinstaller==4.10 \ + --hash=sha256:05c21117b84199272ebd355b556af4714f6e79245e1c435d6f16653786d7d17e \ + --hash=sha256:0dcaf6557cdb2da763c46e06e95a94a7634ab03fb09d91bc77988b01ee05c907 \ + --hash=sha256:15557cd1a79d182967f0a5040750e6902e13ebd6cab41e3ed84d7b28a306357b \ + --hash=sha256:581620bdcd32f01e89b13231256b807bb090e7eadf40c81c864ec402afa4758a \ + --hash=sha256:70c71e827f4b34602cbc7a0947a067b662c1cbdc4db51832e13b97cca3c54dd7 \ + --hash=sha256:714c4dcc319a41416744d1e30c6317405dfaed80d2adc45f8bfa70dc7367e664 \ + --hash=sha256:7749c868d2e2dc84df7d6f65437226183c8a366f3a99bb2737785625c3a3cca1 \ + --hash=sha256:7d94518ba1f8e9a8577345312276891ad7d6cd9785e453e9951b35647e2c7078 \ + --hash=sha256:cfed0b3a43e73550a43a094610328109564710b9514afa093ef7199d072cae87 \ + --hash=sha256:d4f79c0a774451f12baca4e476376418f011fa3039dde8fd172ea2aa8ff67bad \ + --hash=sha256:f2166ff2cd95eefb0d377ae8d1071f186fa25edd410ede65b376162d5ec41909 +setuptools==60.9.3 \ + --hash=sha256:2347b2b432c891a863acadca2da9ac101eae6169b1d3dfee2ec605ecd50dbfe5 \ + --hash=sha256:e4f30b9f84e5ab3decf945113119649fec09c1fc3507c6ebffec75646c56e62b cffi==1.15.0 \ --hash=sha256:00c878c90cb53ccfaae6b8bc18ad05d2036553e6d9d1d9dbcf323bbe83854ca3 \ --hash=sha256:0104fb5ae2391d46a4cb082abdd5c69ea4eab79d8d44eaaf79f1b1fd806ee4c2 \ @@ -68,25 +68,24 @@ cffi==1.15.0 \ --hash=sha256:f6f824dc3bce0edab5f427efcfb1d63ee75b6fcb7282900ccaf925be84efb0fc \ --hash=sha256:fd8a250edc26254fe5b33be00402e6d287f562b6a5b2152dec302fa15bb3e997 \ --hash=sha256:ffaa5c925128e29efbde7301d8ecaf35c8c60ffbcd6a1ffd3a552177c8e5e796 -pycparser==2.20 \ - --hash=sha256:2d475327684562c3a96cc71adf7dc8c4f0565175cf86b6d7a404ff4c771f15f0 \ - --hash=sha256:7582ad22678f0fcd81102833f60ef8d0e57288b6b5fb00323d101be910e35705 -altgraph==0.17 \ - --hash=sha256:1f05a47122542f97028caf78775a095fbe6a2699b5089de8477eb583167d69aa \ - --hash=sha256:c623e5f3408ca61d4016f23a681b9adb100802ca3e3da5e718915a9e4052cebe -macholib==1.14 \ - --hash=sha256:0c436bc847e7b1d9bda0560351bf76d7caf930fb585a828d13608839ef42c432 \ - --hash=sha256:c500f02867515e6c60a27875b408920d18332ddf96b4035ef03beddd782d4281 -pyinstaller-hooks-contrib==2022.0 \ - --hash=sha256:29f0bd8fbb2ff6f2df60a0c147e5b5ad65ae5c1a982d90641a5f712de03fa161 \ - --hash=sha256:61b667f51b2525377fae30793f38fd9752a08032c72b209effabf707c840cc38 -importlib-metadata==3.10.0 \ - --hash=sha256:c9db46394197244adf2f0b08ec5bc3cf16757e9590b02af1fca085c16c0d600a \ - --hash=sha256:d2d46ef77ffc85cbf7dac7e81dd663fde71c45326131bea8033b9bad42268ebe -zipp==3.4.1 \ - --hash=sha256:3607921face881ba3e026887d8150cca609d517579abe052ac81fc5aeffdbd76 \ - --hash=sha256:51cb66cc54621609dd593d1787f286ee42a5c0adbb4b29abea5a63edc3e03098 -typing-extensions==3.7.4.3 \ - --hash=sha256:7cb407020f00f7bfc3cb3e7881628838e69d8f3fcab2f64742a5e76b2f841918 \ - --hash=sha256:99d4073b617d30288f569d3f13d2bd7548c3a7e4c8de87db09a9d29bb3a4a60c \ - --hash=sha256:dafc7639cde7f1b6e1acc0f457842a83e722ccca8eef5270af2d74792619a89f +pycparser==2.21 \ + --hash=sha256:8ee45429555515e1f6b185e78100aea234072576aa43ab53aefcae078162fca9 \ + --hash=sha256:e644fdec12f7872f86c58ff790da456218b10f863970249516d60a5eaca77206 +altgraph==0.17.2 \ + --hash=sha256:743628f2ac6a7c26f5d9223c91ed8ecbba535f506f4b6f558885a8a56a105857 \ + --hash=sha256:ebf2269361b47d97b3b88e696439f6e4cbc607c17c51feb1754f90fb79839158 +macholib==1.15.2 \ + --hash=sha256:1542c41da3600509f91c165cb897e7e54c0e74008bd8da5da7ebbee519d593d2 \ + --hash=sha256:885613dd02d3e26dbd2b541eb4cc4ce611b841f827c0958ab98656e478b9e6f6 +pyinstaller-hooks-contrib==2022.2 \ + --hash=sha256:7605e440ccb55904cb2a87d72e83642ef176fb7030c77e52ac4d9679bb3d1537 \ + --hash=sha256:ab1d14fe053016fff7b0c6aea51d980bac6d02114b04063b46ef7dac70c70e1e +importlib-metadata==4.11.3 \ + --hash=sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6 \ + --hash=sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539 +zipp==3.7.0 \ + --hash=sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d \ + --hash=sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375 +typing-extensions==4.1.1 \ + --hash=sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42 \ + --hash=sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2 diff --git a/build_configs/windows/requirements.txt b/build_configs/windows/requirements.txt index 5b04b2ce..7bf22250 100644 --- a/build_configs/windows/requirements.txt +++ b/build_configs/windows/requirements.txt @@ -2,21 +2,21 @@ -r ../../requirements.txt # Build tools for binary distribution -pyinstaller==4.8 \ - --hash=sha256:15d9266d78dc757c103962826e62bce1513825078160be580534ead2ef53087c \ - --hash=sha256:44783d58ac4cb0a74a4f2180da4dacbe6a7a013a62b3aa10be6082252e296954 \ - --hash=sha256:4c848720a65a5bd41249bc804d1bd3dd089bb56aef7f1c5e11f774f11e649443 \ - --hash=sha256:53ed05214dd67624756fe4e82e861857921a79d0392debf8c9f5bb0ba5a479b6 \ - --hash=sha256:5c2fd5f18c0397f3d9160446035556afc7f6446fd88048887fdf46eadf85c5ec \ - --hash=sha256:6f5cdc39fbdec7b2e0c46cc0f5bd0071bb85e592e324bf4e15375c5ff19e55fc \ - --hash=sha256:7ae868bbcc502832a2c802c84a1dbb9f48b44445c50144c29bfcd7b760140e13 \ - --hash=sha256:9fbb05f5f67862005234da8c7eac69ef87e086f90e345749260051b031774c52 \ - --hash=sha256:b0b3a31aa60292469f9595f298e2c147cba29c30edcd92a38fdce27727809625 \ - --hash=sha256:b720853a00bd9547b7d6403d85f23b7f7e451e41bc907673d9fc7f8d9d274594 \ - --hash=sha256:f00e1296abac71f3b5bb9fdc2e0d4c079201d62faeeeb894ccadd0616179fee3 -setuptools==49.2.0 \ - --hash=sha256:272c7f48f5cddc5af5901f4265274c421c7eede5c8bc454ac2903d3f8fc365e9 \ - --hash=sha256:afe9e81fee0270d3f60d52608549cc8ec4c46dada8c95640c1a00160f577acf2 +pyinstaller==4.10 \ + --hash=sha256:05c21117b84199272ebd355b556af4714f6e79245e1c435d6f16653786d7d17e \ + --hash=sha256:0dcaf6557cdb2da763c46e06e95a94a7634ab03fb09d91bc77988b01ee05c907 \ + --hash=sha256:15557cd1a79d182967f0a5040750e6902e13ebd6cab41e3ed84d7b28a306357b \ + --hash=sha256:581620bdcd32f01e89b13231256b807bb090e7eadf40c81c864ec402afa4758a \ + --hash=sha256:70c71e827f4b34602cbc7a0947a067b662c1cbdc4db51832e13b97cca3c54dd7 \ + --hash=sha256:714c4dcc319a41416744d1e30c6317405dfaed80d2adc45f8bfa70dc7367e664 \ + --hash=sha256:7749c868d2e2dc84df7d6f65437226183c8a366f3a99bb2737785625c3a3cca1 \ + --hash=sha256:7d94518ba1f8e9a8577345312276891ad7d6cd9785e453e9951b35647e2c7078 \ + --hash=sha256:cfed0b3a43e73550a43a094610328109564710b9514afa093ef7199d072cae87 \ + --hash=sha256:d4f79c0a774451f12baca4e476376418f011fa3039dde8fd172ea2aa8ff67bad \ + --hash=sha256:f2166ff2cd95eefb0d377ae8d1071f186fa25edd410ede65b376162d5ec41909 +setuptools==60.9.3 \ + --hash=sha256:2347b2b432c891a863acadca2da9ac101eae6169b1d3dfee2ec605ecd50dbfe5 \ + --hash=sha256:e4f30b9f84e5ab3decf945113119649fec09c1fc3507c6ebffec75646c56e62b cffi==1.15.0 \ --hash=sha256:00c878c90cb53ccfaae6b8bc18ad05d2036553e6d9d1d9dbcf323bbe83854ca3 \ --hash=sha256:0104fb5ae2391d46a4cb082abdd5c69ea4eab79d8d44eaaf79f1b1fd806ee4c2 \ @@ -68,17 +68,17 @@ cffi==1.15.0 \ --hash=sha256:f6f824dc3bce0edab5f427efcfb1d63ee75b6fcb7282900ccaf925be84efb0fc \ --hash=sha256:fd8a250edc26254fe5b33be00402e6d287f562b6a5b2152dec302fa15bb3e997 \ --hash=sha256:ffaa5c925128e29efbde7301d8ecaf35c8c60ffbcd6a1ffd3a552177c8e5e796 -pycparser==2.20 \ - --hash=sha256:2d475327684562c3a96cc71adf7dc8c4f0565175cf86b6d7a404ff4c771f15f0 \ - --hash=sha256:7582ad22678f0fcd81102833f60ef8d0e57288b6b5fb00323d101be910e35705 -altgraph==0.17 \ - --hash=sha256:1f05a47122542f97028caf78775a095fbe6a2699b5089de8477eb583167d69aa \ - --hash=sha256:c623e5f3408ca61d4016f23a681b9adb100802ca3e3da5e718915a9e4052cebe -macholib==1.14 \ - --hash=sha256:0c436bc847e7b1d9bda0560351bf76d7caf930fb585a828d13608839ef42c432 \ - --hash=sha256:c500f02867515e6c60a27875b408920d18332ddf96b4035ef03beddd782d4281 -pefile==2019.4.18 \ - --hash=sha256:a5d6e8305c6b210849b47a6174ddf9c452b2888340b8177874b862ba6c207645 +pycparser==2.21 \ + --hash=sha256:8ee45429555515e1f6b185e78100aea234072576aa43ab53aefcae078162fca9 \ + --hash=sha256:e644fdec12f7872f86c58ff790da456218b10f863970249516d60a5eaca77206 +altgraph==0.17.2 \ + --hash=sha256:743628f2ac6a7c26f5d9223c91ed8ecbba535f506f4b6f558885a8a56a105857 \ + --hash=sha256:ebf2269361b47d97b3b88e696439f6e4cbc607c17c51feb1754f90fb79839158 +macholib==1.15.2 \ + --hash=sha256:1542c41da3600509f91c165cb897e7e54c0e74008bd8da5da7ebbee519d593d2 \ + --hash=sha256:885613dd02d3e26dbd2b541eb4cc4ce611b841f827c0958ab98656e478b9e6f6 +pefile==2021.9.3 \ + --hash=sha256:344a49e40a94e10849f0fe34dddc80f773a12b40675bf2f7be4b8be578bdd94a future==0.18.2 \ --hash=sha256:b1bead90b70cf6ec3f0710ae53a525360fa360d306a86583adc6bf83a4db537d pywin32==303 \ @@ -95,16 +95,15 @@ pywin32==303 \ pywin32-ctypes==0.2.0 \ --hash=sha256:9dc2d991b3479cc2df15930958b674a48a227d5361d413827a4cfd0b5876fc98 \ --hash=sha256:24ffc3b341d457d48e8922352130cf2644024a4ff09762a2261fd34c36ee5942 -pyinstaller-hooks-contrib==2022.0 \ - --hash=sha256:29f0bd8fbb2ff6f2df60a0c147e5b5ad65ae5c1a982d90641a5f712de03fa161 \ - --hash=sha256:61b667f51b2525377fae30793f38fd9752a08032c72b209effabf707c840cc38 -importlib-metadata==3.10.0 \ - --hash=sha256:c9db46394197244adf2f0b08ec5bc3cf16757e9590b02af1fca085c16c0d600a \ - --hash=sha256:d2d46ef77ffc85cbf7dac7e81dd663fde71c45326131bea8033b9bad42268ebe -zipp==3.4.1 \ - --hash=sha256:3607921face881ba3e026887d8150cca609d517579abe052ac81fc5aeffdbd76 \ - --hash=sha256:51cb66cc54621609dd593d1787f286ee42a5c0adbb4b29abea5a63edc3e03098 -typing-extensions==3.7.4.3 \ - --hash=sha256:7cb407020f00f7bfc3cb3e7881628838e69d8f3fcab2f64742a5e76b2f841918 \ - --hash=sha256:99d4073b617d30288f569d3f13d2bd7548c3a7e4c8de87db09a9d29bb3a4a60c \ - --hash=sha256:dafc7639cde7f1b6e1acc0f457842a83e722ccca8eef5270af2d74792619a89f +pyinstaller-hooks-contrib==2022.2 \ + --hash=sha256:7605e440ccb55904cb2a87d72e83642ef176fb7030c77e52ac4d9679bb3d1537 \ + --hash=sha256:ab1d14fe053016fff7b0c6aea51d980bac6d02114b04063b46ef7dac70c70e1e +importlib-metadata==4.11.3 \ + --hash=sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6 \ + --hash=sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539 +zipp==3.7.0 \ + --hash=sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d \ + --hash=sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375 +typing-extensions==4.1.1 \ + --hash=sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42 \ + --hash=sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2 diff --git a/requirements.txt b/requirements.txt index 68a8febb..9738dfb6 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,77 +1,89 @@ -py_ecc==5.1.0 \ - --hash=sha256:1ba0453d39887cdb63e0855ba317b67f8bd571371bb3cafefae3e2e5206e45c5 \ - --hash=sha256:934d6506f8b9487cc669562eb11beaf9b0a9ca408ffd94d0961c9cdde71336f2 -pycryptodome==3.9.8 \ - --hash=sha256:02e51e1d5828d58f154896ddfd003e2e7584869c275e5acbe290443575370fba \ - --hash=sha256:03d5cca8618620f45fd40f827423f82b86b3a202c8d44108601b0f5f56b04299 \ - --hash=sha256:0e24171cf01021bc5dc17d6a9d4f33a048f09d62cc3f62541e95ef104588bda4 \ - --hash=sha256:132a56abba24e2e06a479d8e5db7a48271a73a215f605017bbd476d31f8e71c1 \ - --hash=sha256:1e655746f539421d923fd48df8f6f40b3443d80b75532501c0085b64afed9df5 \ - --hash=sha256:2b998dc45ef5f4e5cf5248a6edfcd8d8e9fb5e35df8e4259b13a1b10eda7b16b \ - --hash=sha256:360955eece2cd0fa694a708d10303c6abd7b39614fa2547b6bd245da76198beb \ - --hash=sha256:39ef9fb52d6ec7728fce1f1693cb99d60ce302aeebd59bcedea70ca3203fda60 \ - --hash=sha256:4350a42028240c344ee855f032c7d4ad6ff4f813bfbe7121547b7dc579ecc876 \ - --hash=sha256:50348edd283afdccddc0938cdc674484533912ba8a99a27c7bfebb75030aa856 \ - --hash=sha256:54bdedd28476dea8a3cd86cb67c0df1f0e3d71cae8022354b0f879c41a3d27b2 \ - --hash=sha256:55eb61aca2c883db770999f50d091ff7c14016f2769ad7bca3d9b75d1d7c1b68 \ - --hash=sha256:6276478ada411aca97c0d5104916354b3d740d368407912722bd4d11aa9ee4c2 \ - --hash=sha256:663f8de2b3df2e744d6e1610506e0ea4e213bde906795953c1e82279c169f0a7 \ - --hash=sha256:67dcad1b8b201308586a8ca2ffe89df1e4f731d5a4cdd0610cc4ea790351c739 \ - --hash=sha256:709b9f144d23e290b9863121d1ace14a72e01f66ea9c903fbdc690520dfdfcf0 \ - --hash=sha256:8063a712fba642f78d3c506b0896846601b6de7f5c3d534e388ad0cc07f5a149 \ - --hash=sha256:80d57177a0b7c14d4594c62bbb47fe2f6309ad3b0a34348a291d570925c97a82 \ - --hash=sha256:87006cf0d81505408f1ae4f55cf8a5d95a8e029a4793360720ae17c6500f7ecc \ - --hash=sha256:9f62d21bc693f3d7d444f17ed2ad7a913b4c37c15cd807895d013c39c0517dfd \ - --hash=sha256:a207231a52426de3ff20f5608f0687261a3329d97a036c51f7d4c606a6f30c23 \ - --hash=sha256:abc2e126c9490e58a36a0f83516479e781d83adfb134576a5cbe5c6af2a3e93c \ - --hash=sha256:b56638d58a3a4be13229c6a815cd448f9e3ce40c00880a5398471b42ee86f50e \ - --hash=sha256:bcd5b8416e73e4b0d48afba3704d8c826414764dafaed7a1a93c442188d90ccc \ - --hash=sha256:bec2bcdf7c9ce7f04d718e51887f3b05dc5c1cfaf5d2c2e9065ecddd1b2f6c9a \ - --hash=sha256:c8bf40cf6e281a4378e25846924327e728a887e8bf0ee83b2604a0f4b61692e8 \ - --hash=sha256:cecbf67e81d6144a50dc615629772859463b2e4f815d0c082fa421db362f040e \ - --hash=sha256:d8074c8448cfd0705dfa71ca333277fce9786d0b9cac75d120545de6253f996a \ - --hash=sha256:dd302b6ae3965afeb5ef1b0d92486f986c0e65183cd7835973f0b593800590e6 \ - --hash=sha256:de6e1cd75677423ff64712c337521e62e3a7a4fc84caabbd93207752e831a85a \ - --hash=sha256:ef39c98d9b8c0736d91937d193653e47c3b19ddf4fc3bccdc5e09aaa4b0c5d21 \ - --hash=sha256:f2e045224074d5664dc9cbabbf4f4d4d46f1ee90f24780e3a9a668fd096ff17f \ - --hash=sha256:f521178e5a991ffd04182ed08f552daca1affcb826aeda0e1945cd989a9d4345 \ - --hash=sha256:f78a68c2c820e4731e510a2df3eef0322f24fde1781ced970bf497b6c7d92982 \ - --hash=sha256:fbe65d5cfe04ff2f7684160d50f5118bdefb01e3af4718eeb618bfed40f19d94 \ - --hash=sha256:be7553b8bea117892f83f52ebfe96929340cacae07f3f6a820291e42168dff62 -click==7.1.2 \ - --hash=sha256:d2b5255c7c6349bc1bd1e59e08cd12acbbd63ce649f2588755783aa94dfb6b1a \ - --hash=sha256:dacca89f4bfadd5de3d7489b7c8a566eee0d3676333fbb50030263894c38c0dc +py-ecc==6.0.0 \ + --hash=sha256:3fc8a79e38975e05dc443d25783fd69212a1ca854cc0efef071301a8f7d6ce1d \ + --hash=sha256:54e8aa4c30374fa62d582c599a99f352c153f2971352171318bd6910a643be0b +pycryptodome==3.14.1 \ + --hash=sha256:028dcbf62d128b4335b61c9fbb7dd8c376594db607ef36d5721ee659719935d5 \ + --hash=sha256:12ef157eb1e01a157ca43eda275fa68f8db0dd2792bc4fe00479ab8f0e6ae075 \ + --hash=sha256:2562de213960693b6d657098505fd4493c45f3429304da67efcbeb61f0edfe89 \ + --hash=sha256:27e92c1293afcb8d2639baf7eb43f4baada86e4de0f1fb22312bfc989b95dae2 \ + --hash=sha256:36e3242c4792e54ed906c53f5d840712793dc68b726ec6baefd8d978c5282d30 \ + --hash=sha256:50a5346af703330944bea503106cd50c9c2212174cfcb9939db4deb5305a8367 \ + --hash=sha256:53dedbd2a6a0b02924718b520a723e88bcf22e37076191eb9b91b79934fb2192 \ + --hash=sha256:69f05aaa90c99ac2f2af72d8d7f185f729721ad7c4be89e9e3d0ab101b0ee875 \ + --hash=sha256:75a3a364fee153e77ed889c957f6f94ec6d234b82e7195b117180dcc9fc16f96 \ + --hash=sha256:766a8e9832128c70012e0c2b263049506cbf334fb21ff7224e2704102b6ef59e \ + --hash=sha256:7fb90a5000cc9c9ff34b4d99f7f039e9c3477700e309ff234eafca7b7471afc0 \ + --hash=sha256:893f32210de74b9f8ac869ed66c97d04e7d351182d6d39ebd3b36d3db8bda65d \ + --hash=sha256:8b5c28058102e2974b9868d72ae5144128485d466ba8739abd674b77971454cc \ + --hash=sha256:924b6aad5386fb54f2645f22658cb0398b1f25bc1e714a6d1522c75d527deaa5 \ + --hash=sha256:9924248d6920b59c260adcae3ee231cd5af404ac706ad30aa4cd87051bf09c50 \ + --hash=sha256:9ec761a35dbac4a99dcbc5cd557e6e57432ddf3e17af8c3c86b44af9da0189c0 \ + --hash=sha256:a36ab51674b014ba03da7f98b675fcb8eabd709a2d8e18219f784aba2db73b72 \ + --hash=sha256:aae395f79fa549fb1f6e3dc85cf277f0351e15a22e6547250056c7f0c990d6a5 \ + --hash=sha256:c880a98376939165b7dc504559f60abe234b99e294523a273847f9e7756f4132 \ + --hash=sha256:ce7a875694cd6ccd8682017a7c06c6483600f151d8916f2b25cf7a439e600263 \ + --hash=sha256:d1b7739b68a032ad14c5e51f7e4e1a5f92f3628bba024a2bda1f30c481fc85d8 \ + --hash=sha256:dcd65355acba9a1d0fc9b923875da35ed50506e339b35436277703d7ace3e222 \ + --hash=sha256:e04e40a7f8c1669195536a37979dd87da2c32dbdc73d6fe35f0077b0c17c803b \ + --hash=sha256:e0c04c41e9ade19fbc0eff6aacea40b831bfcb2c91c266137bcdfd0d7b2f33ba \ + --hash=sha256:e24d4ec4b029611359566c52f31af45c5aecde7ef90bf8f31620fd44c438efe7 \ + --hash=sha256:e64738207a02a83590df35f59d708bf1e7ea0d6adce712a777be2967e5f7043c \ + --hash=sha256:ea56a35fd0d13121417d39a83f291017551fa2c62d6daa6b04af6ece7ed30d84 \ + --hash=sha256:f2772af1c3ef8025c85335f8b828d0193fa1e43256621f613280e2c81bfad423 \ + --hash=sha256:f403a3e297a59d94121cb3ee4b1cf41f844332940a62d71f9e4a009cc3533493 \ + --hash=sha256:f572a3ff7b6029dd9b904d6be4e0ce9e309dcb847b03e3ac8698d9d23bb36525 +click==8.0.4 \ + --hash=sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1 \ + --hash=sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb ssz==0.2.4 \ --hash=sha256:3c944cd97a38448fe2b145d80d704bd28bc3c5368da9624177b0964e37adaf7e \ --hash=sha256:99c4a7bbaf632113fc28beb8770673637286f7fdade1231e0a2c6fae6331c06d -eth-typing==2.2.2 \ - --hash=sha256:1140c7592321dbf10d6663c46f7e43eb0e6410b011b03f14b3df3eb1f76aa9bb \ - --hash=sha256:97ba0f83da7cf1d3668f6ed54983f21168076c552762bf5e06d4a20921877f3f +eth-typing==3.0.0 \ + --hash=sha256:079e4c41e98cf2635d3830a99f3cbd7b1d73d2368464d4493c002bece545184a \ + --hash=sha256:fb96f5eaa844b8be7727d590a54a952a42e5021426f98074b06b23ae43de5867 # Dependencies for the above -eth-utils==1.9.5 \ - --hash=sha256:11597842b0148c39d2638ad55897f9243479a8369be713b238b0684f8750215e \ - --hash=sha256:ac168aaa241fa0665e758b04009259d1b2b35daa0615fc563aad29f9ffc64d56 +eth-utils==2.0.0 \ + --hash=sha256:209dc12255398f2a88f12de78f338b974861f9aefa981af5b68a5d102c9b2043 \ + --hash=sha256:32f50edb14c5be0c4f0e8c2e6117286ccc5dfda21d170f358add554a048398e3 mypy-extensions==0.4.3 \ --hash=sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d \ --hash=sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8 -lru-dict==1.1.6 \ - --hash=sha256:365457660e3d05b76f1aba3e0f7fedbfcd6528e97c5115a351ddd0db488354cc \ - --hash=sha256:288d8794e9376fe31d27abc3531d395675b2a910781f26034d5ef79f0ba9cecc -pyrsistent==0.16.1 \ - --hash=sha256:aa2ae1c2e496f4d6777f869ea5de7166a8ccb9c2e06ebcf6c7ff1b670c98c5ef -eth-hash==0.2.0 \ - --hash=sha256:1b9cb34dd3cd99c85c2bd6a1420ceae39a2eee8bf080efd264bcda8be3edecc8 \ - --hash=sha256:499dc02d098f69856d1a6dd005529c16174157d4fb2a9fe20c41f69e39f8f176 +lru-dict==1.1.7 \ + --hash=sha256:45b81f67d75341d4433abade799a47e9c42a9e22a118531dcb5e549864032d7c +pyrsistent==0.18.1 \ + --hash=sha256:0e3e1fcc45199df76053026a51cc59ab2ea3fc7c094c6627e93b7b44cdae2c8c \ + --hash=sha256:1b34eedd6812bf4d33814fca1b66005805d3640ce53140ab8bbb1e2651b0d9bc \ + --hash=sha256:4ed6784ceac462a7d6fcb7e9b663e93b9a6fb373b7f43594f9ff68875788e01e \ + --hash=sha256:5d45866ececf4a5fff8742c25722da6d4c9e180daa7b405dc0a2a2790d668c26 \ + --hash=sha256:636ce2dc235046ccd3d8c56a7ad54e99d5c1cd0ef07d9ae847306c91d11b5fec \ + --hash=sha256:6455fc599df93d1f60e1c5c4fe471499f08d190d57eca040c0ea182301321286 \ + --hash=sha256:6bc66318fb7ee012071b2792024564973ecc80e9522842eb4e17743604b5e045 \ + --hash=sha256:7bfe2388663fd18bd8ce7db2c91c7400bf3e1a9e8bd7d63bf7e77d39051b85ec \ + --hash=sha256:7ec335fc998faa4febe75cc5268a9eac0478b3f681602c1f27befaf2a1abe1d8 \ + --hash=sha256:914474c9f1d93080338ace89cb2acee74f4f666fb0424896fcfb8d86058bf17c \ + --hash=sha256:b568f35ad53a7b07ed9b1b2bae09eb15cdd671a5ba5d2c66caee40dbf91c68ca \ + --hash=sha256:cdfd2c361b8a8e5d9499b9082b501c452ade8bbf42aef97ea04854f4a3f43b22 \ + --hash=sha256:d1b96547410f76078eaf66d282ddca2e4baae8964364abb4f4dcdde855cd123a \ + --hash=sha256:d4d61f8b993a7255ba714df3aca52700f8125289f84f704cf80916517c46eb96 \ + --hash=sha256:d7a096646eab884bf8bed965bad63ea327e0d0c38989fc83c5ea7b8a87037bfc \ + --hash=sha256:df46c854f490f81210870e509818b729db4488e1f30f2a1ce1698b2295a878d1 \ + --hash=sha256:e24a828f57e0c337c8d8bb9f6b12f09dfdf0273da25fda9e314f0b684b415a07 \ + --hash=sha256:e4f3149fd5eb9b285d6bfb54d2e5173f6a116fe19172686797c056672689daf6 \ + --hash=sha256:e92a52c166426efbe0d1ec1332ee9119b6d32fc1f0bbfd55d5c1088070e7fc1b \ + --hash=sha256:f87cc2863ef33c709e237d4b5f4502a62a00fab450c9e020892e8e2ede5847f5 \ + --hash=sha256:fd8da6d0124efa2f67d86fa70c851022f87c98e205f0594e1fae044e7119a5a6 +eth-hash==0.3.2 \ + --hash=sha256:3f40cecd5ead88184aa9550afc19d057f103728108c5102f592f8415949b5a76 \ + --hash=sha256:de7385148a8e0237ba1240cddbc06d53f56731140f8593bdb8429306f6b42271 cytoolz==0.11.2 \ --hash=sha256:ea23663153806edddce7e4153d1d407d62357c05120a4e8485bddf1bd5ab22b4 -toolz==0.10.0 \ - --hash=sha256:08fdd5ef7c96480ad11c12d472de21acd32359996f69a5259299b540feba4560 \ - --hash=sha256:e71d8d91c8902fb7659c23e10e9698a8c5cbea985683b8a378c6fd67b52f2fc4 \ - --hash=sha256:c43f7cffb32a3c8e3fb51192cae4dcdbf0a6fee4d07142ca2e443d2bd9f89400 -six==1.15.0 \ - --hash=sha256:30639c035cdb23534cd4aa2dd52c3bf48f06e5f4a941509c8bafd8ce11080259 \ - --hash=sha256:8b74bedcbbbaca38ff6d7491d76f2b06b3592611af620f8426e82dddb04a5ced +toolz==0.11.2 \ + --hash=sha256:6b312d5e15138552f1bda8a4e66c30e236c831b612b2bf0005f8a1df10a4bc33 \ + --hash=sha256:a5700ce83414c64514d82d60bcda8aabfde092d1c1a8663f9200c07fdcc6da8f +six==1.16.0 \ + --hash=sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926 \ + --hash=sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254 cached-property==1.5.2 \ --hash=sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130 \ --hash=sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0 diff --git a/requirements_test.txt b/requirements_test.txt index f4d1a3fc..6aa557d0 100644 --- a/requirements_test.txt +++ b/requirements_test.txt @@ -2,61 +2,68 @@ -r requirements.txt # Testing -pytest==6.0.2 \ - --hash=sha256:0e37f61339c4578776e090c3b8f6b16ce4db333889d65d0efb305243ec544b40 \ - --hash=sha256:c8f57c2a30983f469bf03e68cdfa74dc474ce56b8f280ddcb080dfd91df01043 -pytest-asyncio==0.14.0 \ - --hash=sha256:2eae1e34f6c68fc0a9dc12d4bea190483843ff4708d24277c41568d6b6044f1d \ - --hash=sha256:9882c0c6b24429449f5f969a5158b528f39bde47dc32e85b9f0403965017e700 -flake8==3.8.3 \ - --hash=sha256:15e351d19611c887e482fb960eae4d44845013cc142d42896e9862f775d8cf5c \ - --hash=sha256:f04b9fcbac03b0a3e58c0ab3a0ecc462e023a9faf046d57794184028123aa208 -mypy==0.931 \ - --hash=sha256:1171f2e0859cfff2d366da2c7092b06130f232c636a3f7301e3feb8b41f6377d \ - --hash=sha256:7b3f6f557ba4afc7f2ce6d3215d5db279bcf120b3cfd0add20a5d4f4abdae5bc \ - --hash=sha256:300717a07ad09525401a508ef5d105e6b56646f7942eb92715a1c8d610149714 \ - --hash=sha256:c89702cac5b302f0c5d33b172d2b55b5df2bede3344a2fbed99ff96bddb2cf00 \ - --hash=sha256:3c5b42d0815e15518b1f0990cff7a705805961613e701db60387e6fb663fe78a \ - --hash=sha256:74f7eccbfd436abe9c352ad9fb65872cc0f1f0a868e9d9c44db0893440f0c697 \ - --hash=sha256:8ca7f8c4b1584d63c9a0f827c37ba7a47226c19a23a753d52e5b5eddb201afcd \ - --hash=sha256:5b56154f8c09427bae082b32275a21f500b24d93c88d69a5e82f3978018a0266 \ - --hash=sha256:ff3bf387c14c805ab1388185dd22d6b210824e164d4bb324b195ff34e322d166 \ - --hash=sha256:d9d2b84b2007cea426e327d2483238f040c49405a6bf4074f605f0156c91a47a \ - --hash=sha256:8c11003aaeaf7cc2d0f1bc101c1cc9454ec4cc9cb825aef3cafff8a5fdf4c799 \ - --hash=sha256:1b06268df7eb53a8feea99cbfff77a6e2b205e70bf31743e786678ef87ee8069 \ - --hash=sha256:f9fe20d0872b26c4bba1c1be02c5340de1019530302cf2dcc85c7f9fc3252ae0 \ - --hash=sha256:d8f1ff62f7a879c9fe5917b3f9eb93a79b78aad47b533911b853a757223f72e7 \ - --hash=sha256:50c7346a46dc76a4ed88f3277d4959de8a2bd0a0fa47fa87a4cde36fe247ac05 \ - --hash=sha256:e839191b8da5b4e5d805f940537efcaa13ea5dd98418f06dc585d2891d228cf0 +pytest==7.1.0 \ + --hash=sha256:b555252a95bbb2a37a97b5ac2eb050c436f7989993565f5e0c9128fcaacadd0e \ + --hash=sha256:f1089d218cfcc63a212c42896f1b7fbf096874d045e1988186861a1a87d27b47 +pytest-asyncio==0.18.2 \ + --hash=sha256:20db0bdd3d7581b2e11f5858a5d9541f2db9cd8c5853786f94ad273d466c8c6d \ + --hash=sha256:fc8e4190f33fee7797cc7f1829f46a82c213f088af5d1bb5d4e454fe87e6cdc2 +flake8==4.0.1 \ + --hash=sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d \ + --hash=sha256:806e034dda44114815e23c16ef92f95c91e4c71100ff52813adf7132a6ad870d +mypy==0.941 \ + --hash=sha256:080097eee5393fd740f32c63f9343580aaa0fb1cda0128fd859dfcf081321c3d \ + --hash=sha256:0d3bcbe146247997e03bf030122000998b076b3ac6925b0b6563f46d1ce39b50 \ + --hash=sha256:0dd441fbacf48e19dc0c5c42fafa72b8e1a0ba0a39309c1af9c84b9397d9b15a \ + --hash=sha256:108f3c7e14a038cf097d2444fa0155462362c6316e3ecb2d70f6dd99cd36084d \ + --hash=sha256:3bada0cf7b6965627954b3a128903a87cac79a79ccd83b6104912e723ef16c7b \ + --hash=sha256:3cf77f138efb31727ee7197bc824c9d6d7039204ed96756cc0f9ca7d8e8fc2a4 \ + --hash=sha256:42c216a33d2bdba08098acaf5bae65b0c8196afeb535ef4b870919a788a27259 \ + --hash=sha256:465a6ce9ca6268cadfbc27a2a94ddf0412568a6b27640ced229270be4f5d394d \ + --hash=sha256:6a8e1f63357851444940351e98fb3252956a15f2cabe3d698316d7a2d1f1f896 \ + --hash=sha256:745071762f32f65e77de6df699366d707fad6c132a660d1342077cbf671ef589 \ + --hash=sha256:818cfc51c25a5dbfd0705f3ac1919fff6971eb0c02e6f1a1f6a017a42405a7c0 \ + --hash=sha256:8e5974583a77d630a5868eee18f85ac3093caf76e018c510aeb802b9973304ce \ + --hash=sha256:8eaf55fdf99242a1c8c792247c455565447353914023878beadb79600aac4a2a \ + --hash=sha256:98f61aad0bb54f797b17da5b82f419e6ce214de0aa7e92211ebee9e40eb04276 \ + --hash=sha256:b2ce2788df0c066c2ff4ba7190fa84f18937527c477247e926abeb9b1168b8cc \ + --hash=sha256:b30d29251dff4c59b2e5a1fa1bab91ff3e117b4658cb90f76d97702b7a2ae699 \ + --hash=sha256:bf446223b2e0e4f0a4792938e8d885e8a896834aded5f51be5c3c69566495540 \ + --hash=sha256:cbcc691d8b507d54cb2b8521f0a2a3d4daa477f62fe77f0abba41e5febb377b7 \ + --hash=sha256:d051ce0946521eba48e19b25f27f98e5ce4dbc91fff296de76240c46b4464df0 \ + --hash=sha256:d61b73c01fc1de799226963f2639af831307fe1556b04b7c25e2b6c267a3bc76 \ + --hash=sha256:eea10982b798ff0ccc3b9e7e42628f932f552c5845066970e67cd6858655d52c \ + --hash=sha256:f79137d012ff3227866222049af534f25354c07a0d6b9a171dba9f1d6a1fdef4 \ + --hash=sha256:fc5ecff5a3bbfbe20091b1cad82815507f5ae9c380a3a9bf40f740c70ce30a9b # Dependencies for the above wcwidth==0.2.5 \ --hash=sha256:beb4802a9cebb9144e99086eff703a642a13d6a0052920003a230f3294bbe784 \ --hash=sha256:c4d647b99872929fdb7bdcaa4fbe7f01413ed3d98077df798530e5b04f116c83 -pluggy==0.13.1 \ - --hash=sha256:15b2acde666561e1298d71b523007ed7364de07029219b604cf808bfa1c765b0 \ - --hash=sha256:966c145cd83c96502c3c3868f50408687b38434af77734af1e9ca461a4081d2d -importlib-metadata==1.7.0 \ - --hash=sha256:90bb658cdbbf6d1735b6341ce708fc7024a3e14e99ffdc5783edea9f9b077f83 \ - --hash=sha256:dc15b2969b4ce36305c51eebe62d418ac7791e9a157911d58bfb1f9ccd8e2070 -attrs==20.2.0 \ - --hash=sha256:26b54ddbbb9ee1d34d5d3668dd37d6cf74990ab23c828c2888dccdceee395594 \ - --hash=sha256:fce7fc47dfc976152e82d53ff92fa0407700c21acd20886a13777a0d20e655dc -entrypoints==0.3 \ - --hash=sha256:589f874b313739ad35be6e0cd7efde2a4e9b6fea91edcc34e58ecbb8dbe56d19 \ - --hash=sha256:c70dd71abe5a8c85e55e12c19bd91ccfeec11a6e99044204511f9ed547d48451 -pycodestyle==2.6.0 \ - --hash=sha256:2295e7b2f6b5bd100585ebcb1f616591b652db8a741695b3d8f5d28bdc934367 \ - --hash=sha256:c58a7d2815e0e8d7972bf1803331fb0152f867bd89adf8a01dfd55085434192e -pyflakes==2.2.0 \ - --hash=sha256:0d94e0e05a19e57a99444b6ddcf9a6eb2e5c68d3ca1e98e90707af8152c90a92 \ - --hash=sha256:35b2d75ee967ea93b55750aa9edbbf72813e06a66ba54438df2cfac9e3c27fc8 -mccabe==0.6.1 \ - --hash=sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42 \ - --hash=sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f -typing-extensions==4.0.1 \ - --hash=sha256:4ca091dea149f945ec56afb48dae714f21e8692ef22a395223bcd328961b6a0e \ - --hash=sha256:7f001e5ac290a0c0401508864c7ec868be4e701886d5b573a9528ed3973d9d3b +pluggy==1.0.0 \ + --hash=sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159 \ + --hash=sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3 +importlib-metadata==4.11.3 \ + --hash=sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6 \ + --hash=sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539 +attrs==21.4.0 \ + --hash=sha256:2d27e3784d7a565d36ab851fe94887c5eccd6a463168875832a1be79c82828b4 \ + --hash=sha256:626ba8234211db98e869df76230a137c4c40a12d72445c45d5f5b716f076e2fd +entrypoints==0.4 \ + --hash=sha256:b706eddaa9218a19ebcd67b56818f05bb27589b1ca9e8d797b74affad4ccacd4 \ + --hash=sha256:f174b5ff827504fd3cd97cc3f8649f3693f51538c7e4bdf3ef002c8429d42f9f +pycodestyle==2.8.0 \ + --hash=sha256:720f8b39dde8b293825e7ff02c475f3077124006db4f440dcbc9a20b76548a20 \ + --hash=sha256:eddd5847ef438ea1c7870ca7eb78a9d47ce0cdb4851a5523949f2601d0cbbe7f +pyflakes==2.4.0 \ + --hash=sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c \ + --hash=sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e +mccabe==0.7.0 \ + --hash=sha256:348e0240c33b60bbdf4e523192ef919f28cb2c3d7d5c7794f74009290f236325 \ + --hash=sha256:6c2d30ab6be0e4a46919781807b4f0d834ebdd6c6e3dca0bda5a15f863427b6e +typing-extensions==4.1.1 \ + --hash=sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42 \ + --hash=sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2 typed-ast==1.5.2 \ --hash=sha256:18fe320f354d6f9ad3147859b6e16649a0781425268c4dde596093177660e71a \ --hash=sha256:bc2542e83ac8399752bc16e0b35e038bdb659ba237f4222616b4e83fb9654985 \ @@ -77,36 +84,36 @@ typed-ast==1.5.2 \ --hash=sha256:c7407cfcad702f0b6c0e0f3e7ab876cd1d2c13b14ce770e412c0c4b9728a0f88 \ --hash=sha256:f30ddd110634c2d7534b2d4e0e22967e88366b0d356b24de87419cc4410c41b7 \ --hash=sha256:26a432dc219c6b6f38be20a958cbe1abffcc5492821d7e27f08606ef99e0dffd -packaging==20.4 \ - --hash=sha256:4357f74f47b9c12db93624a82154e9b120fa8293699949152b22065d556079f8 \ - --hash=sha256:998416ba6962ae7fbd6596850b80e17859a5753ba17c32284f67bfff33784181 -more-itertools==8.5.0 \ - --hash=sha256:6f83822ae94818eae2612063a5101a7311e68ae8002005b5e05f03fd74a86a20 \ - --hash=sha256:9b30f12df9393f0d28af9210ff8efe48d10c94f73e5daf886f10c4b0b0b4f03c -py==1.10.0 \ - --hash=sha256:3b80836aa6d1feeaa108e046da6423ab8f6ceda6468545ae8d02d9d58d18818a \ - --hash=sha256:21b81bda15b66ef5e1a777a21c4dcd9c20ad3efd0b3f817e7a809035269e1bd3 -zipp==3.1.0 \ - --hash=sha256:aa36550ff0c0b7ef7fa639055d797116ee891440eac1a56f378e2d3179e0320b \ - --hash=sha256:c599e4d75c98f6798c509911d08a22e6c021d074469042177c8c86fb92eefd96 -pyparsing==2.4.7 \ - --hash=sha256:ef9d7589ef3c200abe66653d3f1ab1033c3c419ae9b9bdb1240a85b024efc88b \ - --hash=sha256:c203ec8783bf771a155b207279b9bccb8dea02d8f0c9e5f8ead507bc3246ecc1 -colorama==0.4.3 \ - --hash=sha256:7d73d2a99753107a36ac6b455ee49046802e59d9d076ef8e47b61499fa29afff \ - --hash=sha256:e96da0d330793e2cb9485e9ddfd918d456036c7149416295932478192f4436a1 +packaging==21.3 \ + --hash=sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb \ + --hash=sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522 +more-itertools==8.12.0 \ + --hash=sha256:43e6dd9942dffd72661a2c4ef383ad7da1e6a3e968a927ad7a6083ab410a688b \ + --hash=sha256:7dc6ad46f05f545f900dd59e8dfb4e84a4827b97b3cfecb175ea0c7d247f6064 +py==1.11.0 \ + --hash=sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719 \ + --hash=sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378 +zipp==3.7.0 \ + --hash=sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d \ + --hash=sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375 +pyparsing==3.0.7 \ + --hash=sha256:18ee9022775d270c55187733956460083db60b37d0d0fb357445f3094eed3eea \ + --hash=sha256:a6c06a88f252e6c322f65faf8f418b16213b51bdfaece0524c1c1bc30c63c484 +colorama==0.4.4 \ + --hash=sha256:5941b2b48a20143d2267e95b1c2a7603ce057ee39fd88e7329b0c292aa16869b \ + --hash=sha256:9f47eda37229f68eee03b24b9748937c7dc3868f906e8ba69fbcbdd3bc5dc3e2 atomicwrites==1.4.0 \ --hash=sha256:6d1784dea7c0c8d4a5172b6c620f40b6e4cbfdf96d783691f2e1302a7b88e197 \ --hash=sha256:ae70396ad1a434f9c7046fd2dd196fc04b12f9e91ffb859164193be8b6168a7a -iniconfig==1.0.1 \ - --hash=sha256:80cf40c597eb564e86346103f609d74efce0f6b4d4f30ec8ce9e2c26411ba437 \ - --hash=sha256:e5f92f89355a67de0595932a6c6c02ab4afddc6fcdc0bfc5becd0d60884d3f69 -toml==0.10.1 \ - --hash=sha256:926b612be1e5ce0634a2ca03470f95169cf16f939018233a670519cb4ac58b0f \ - --hash=sha256:bda89d5935c2eac546d648028b9901107a595863cb36bae0c73ac804a9b4ce88 -tomli==2.0.0 \ - --hash=sha256:c292c34f58502a1eb2bbb9f5bbc9a5ebc37bee10ffb8c2d6bbdfa8eb13cc14e1 \ - --hash=sha256:b5bde28da1fed24b9bd1d4d2b8cba62300bfb4ec9a6187a957e8ddb9434c5224 -jsonschema==3.2.0 \ - --hash=sha256:4e5b3cf8216f577bee9ce139cbe72eca3ea4f292ec60928ff24758ce626cd163 \ - --hash=sha256:c8a85b28d377cc7737e46e2d9f2b4f44ee3c0e1deac6bf46ddefc7187d30797a +iniconfig==1.1.1 \ + --hash=sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3 \ + --hash=sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32 +toml==0.10.2 \ + --hash=sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b \ + --hash=sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f +tomli==2.0.1 \ + --hash=sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc \ + --hash=sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f +jsonschema==4.4.0 \ + --hash=sha256:636694eb41b3535ed608fe04129f26542b59ed99808b4f688aa32dcf55317a83 \ + --hash=sha256:77281a1f71684953ee8b3d488371b162419767973789272434bbc3f29d9c8823 From e84e9422eb554e2d6cdde6a85c28cadb89c6af38 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Wed, 16 Mar 2022 14:46:34 +0100 Subject: [PATCH 03/56] resolves version conflicts --- requirements.txt | 42 +++++++++++------------------------------- requirements_test.txt | 9 ++++++--- 2 files changed, 17 insertions(+), 34 deletions(-) diff --git a/requirements.txt b/requirements.txt index 9738dfb6..7671fc45 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,6 +1,6 @@ -py-ecc==6.0.0 \ - --hash=sha256:3fc8a79e38975e05dc443d25783fd69212a1ca854cc0efef071301a8f7d6ce1d \ - --hash=sha256:54e8aa4c30374fa62d582c599a99f352c153f2971352171318bd6910a643be0b +py-ecc==5.2.0 \ + --hash=sha256:525b95aae5bbc185baff7dbfdb9bbd14d2c9454a797457f3edc85fd14c2ad7a6 \ + --hash=sha256:f0aabdc82813ecb2e75e0531e3850295ff1a96bedfba42f15b5bc7f39ced64ba pycryptodome==3.14.1 \ --hash=sha256:028dcbf62d128b4335b61c9fbb7dd8c376594db607ef36d5721ee659719935d5 \ --hash=sha256:12ef157eb1e01a157ca43eda275fa68f8db0dd2792bc4fe00479ab8f0e6ae075 \ @@ -38,41 +38,21 @@ click==8.0.4 \ ssz==0.2.4 \ --hash=sha256:3c944cd97a38448fe2b145d80d704bd28bc3c5368da9624177b0964e37adaf7e \ --hash=sha256:99c4a7bbaf632113fc28beb8770673637286f7fdade1231e0a2c6fae6331c06d -eth-typing==3.0.0 \ - --hash=sha256:079e4c41e98cf2635d3830a99f3cbd7b1d73d2368464d4493c002bece545184a \ - --hash=sha256:fb96f5eaa844b8be7727d590a54a952a42e5021426f98074b06b23ae43de5867 +eth-typing==2.3.0 \ + --hash=sha256:39cce97f401f082739b19258dfa3355101c64390914c73fe2b90012f443e0dc7 \ + --hash=sha256:b7fa58635c1cb0cbf538b2f5f1e66139575ea4853eac1d6000f0961a4b277422 # Dependencies for the above -eth-utils==2.0.0 \ - --hash=sha256:209dc12255398f2a88f12de78f338b974861f9aefa981af5b68a5d102c9b2043 \ - --hash=sha256:32f50edb14c5be0c4f0e8c2e6117286ccc5dfda21d170f358add554a048398e3 +eth-utils==1.10.0 \ + --hash=sha256:74240a8c6f652d085ed3c85f5f1654203d2f10ff9062f83b3bad0a12ff321c7a \ + --hash=sha256:bf82762a46978714190b0370265a7148c954d3f0adaa31c6f085ea375e4c61af mypy-extensions==0.4.3 \ --hash=sha256:090fedd75945a69ae91ce1303b5824f428daf5a028d2f6ab8a299250a846f15d \ --hash=sha256:2d82818f5bb3e369420cb3c4060a7970edba416647068eb4c5343488a6c604a8 lru-dict==1.1.7 \ --hash=sha256:45b81f67d75341d4433abade799a47e9c42a9e22a118531dcb5e549864032d7c -pyrsistent==0.18.1 \ - --hash=sha256:0e3e1fcc45199df76053026a51cc59ab2ea3fc7c094c6627e93b7b44cdae2c8c \ - --hash=sha256:1b34eedd6812bf4d33814fca1b66005805d3640ce53140ab8bbb1e2651b0d9bc \ - --hash=sha256:4ed6784ceac462a7d6fcb7e9b663e93b9a6fb373b7f43594f9ff68875788e01e \ - --hash=sha256:5d45866ececf4a5fff8742c25722da6d4c9e180daa7b405dc0a2a2790d668c26 \ - --hash=sha256:636ce2dc235046ccd3d8c56a7ad54e99d5c1cd0ef07d9ae847306c91d11b5fec \ - --hash=sha256:6455fc599df93d1f60e1c5c4fe471499f08d190d57eca040c0ea182301321286 \ - --hash=sha256:6bc66318fb7ee012071b2792024564973ecc80e9522842eb4e17743604b5e045 \ - --hash=sha256:7bfe2388663fd18bd8ce7db2c91c7400bf3e1a9e8bd7d63bf7e77d39051b85ec \ - --hash=sha256:7ec335fc998faa4febe75cc5268a9eac0478b3f681602c1f27befaf2a1abe1d8 \ - --hash=sha256:914474c9f1d93080338ace89cb2acee74f4f666fb0424896fcfb8d86058bf17c \ - --hash=sha256:b568f35ad53a7b07ed9b1b2bae09eb15cdd671a5ba5d2c66caee40dbf91c68ca \ - --hash=sha256:cdfd2c361b8a8e5d9499b9082b501c452ade8bbf42aef97ea04854f4a3f43b22 \ - --hash=sha256:d1b96547410f76078eaf66d282ddca2e4baae8964364abb4f4dcdde855cd123a \ - --hash=sha256:d4d61f8b993a7255ba714df3aca52700f8125289f84f704cf80916517c46eb96 \ - --hash=sha256:d7a096646eab884bf8bed965bad63ea327e0d0c38989fc83c5ea7b8a87037bfc \ - --hash=sha256:df46c854f490f81210870e509818b729db4488e1f30f2a1ce1698b2295a878d1 \ - --hash=sha256:e24a828f57e0c337c8d8bb9f6b12f09dfdf0273da25fda9e314f0b684b415a07 \ - --hash=sha256:e4f3149fd5eb9b285d6bfb54d2e5173f6a116fe19172686797c056672689daf6 \ - --hash=sha256:e92a52c166426efbe0d1ec1332ee9119b6d32fc1f0bbfd55d5c1088070e7fc1b \ - --hash=sha256:f87cc2863ef33c709e237d4b5f4502a62a00fab450c9e020892e8e2ede5847f5 \ - --hash=sha256:fd8da6d0124efa2f67d86fa70c851022f87c98e205f0594e1fae044e7119a5a6 +pyrsistent==0.16.1 \ + --hash=sha256:aa2ae1c2e496f4d6777f869ea5de7166a8ccb9c2e06ebcf6c7ff1b670c98c5ef eth-hash==0.3.2 \ --hash=sha256:3f40cecd5ead88184aa9550afc19d057f103728108c5102f592f8415949b5a76 \ --hash=sha256:de7385148a8e0237ba1240cddbc06d53f56731140f8593bdb8429306f6b42271 diff --git a/requirements_test.txt b/requirements_test.txt index 6aa557d0..0a4f031f 100644 --- a/requirements_test.txt +++ b/requirements_test.txt @@ -58,9 +58,9 @@ pycodestyle==2.8.0 \ pyflakes==2.4.0 \ --hash=sha256:05a85c2872edf37a4ed30b0cce2f6093e1d0581f8c19d7393122da7e25b2b24c \ --hash=sha256:3bb3a3f256f4b7968c9c788781e4ff07dce46bdf12339dcda61053375426ee2e -mccabe==0.7.0 \ - --hash=sha256:348e0240c33b60bbdf4e523192ef919f28cb2c3d7d5c7794f74009290f236325 \ - --hash=sha256:6c2d30ab6be0e4a46919781807b4f0d834ebdd6c6e3dca0bda5a15f863427b6e +mccabe==0.6.1 \ + --hash=sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42 \ + --hash=sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f typing-extensions==4.1.1 \ --hash=sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42 \ --hash=sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2 @@ -117,3 +117,6 @@ tomli==2.0.1 \ jsonschema==4.4.0 \ --hash=sha256:636694eb41b3535ed608fe04129f26542b59ed99808b4f688aa32dcf55317a83 \ --hash=sha256:77281a1f71684953ee8b3d488371b162419767973789272434bbc3f29d9c8823 +importlib-resources==5.4.0 \ + --hash=sha256:33a95faed5fc19b4bc16b29a6eeae248a3fe69dd55d4d229d2b480e23eeaad45 \ + --hash=sha256:d756e2f85dd4de2ba89be0b21dba2a3bbec2e871a42a3a16719258a11f87506b From 925960fcaf17d40444448e1822ae4374f04821d1 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Wed, 16 Mar 2022 15:28:13 +0100 Subject: [PATCH 04/56] unify function sigs to make click happy --- staking_deposit/utils/click.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/staking_deposit/utils/click.py b/staking_deposit/utils/click.py index 8b9b2ae3..85b5b87a 100644 --- a/staking_deposit/utils/click.py +++ b/staking_deposit/utils/click.py @@ -52,9 +52,9 @@ def get_help_record(self, ctx: click.Context) -> Tuple[str, str]: self.help = _value_of(self.callable_help) return super().get_help_record(ctx) - def get_default(self, ctx: click.Context) -> Any: + def get_default(self, ctx: click.Context, call: bool = True) -> Any: self.default = _value_of(self.callable_default) - return super().get_default(ctx) + return super().get_default(ctx, call) def jit_option(*args: Any, **kwargs: Any) -> Callable[[Any], Any]: From fd74dfdbc5351bd6adcbe3ffdbd1d3a1b444fd28 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 18:42:53 +0100 Subject: [PATCH 05/56] revert click to 7.1.2 again --- requirements.txt | 6 +++--- staking_deposit/utils/click.py | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/requirements.txt b/requirements.txt index 7671fc45..a936538e 100644 --- a/requirements.txt +++ b/requirements.txt @@ -32,9 +32,9 @@ pycryptodome==3.14.1 \ --hash=sha256:f2772af1c3ef8025c85335f8b828d0193fa1e43256621f613280e2c81bfad423 \ --hash=sha256:f403a3e297a59d94121cb3ee4b1cf41f844332940a62d71f9e4a009cc3533493 \ --hash=sha256:f572a3ff7b6029dd9b904d6be4e0ce9e309dcb847b03e3ac8698d9d23bb36525 -click==8.0.4 \ - --hash=sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1 \ - --hash=sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb +click==7.1.2 \ + --hash=sha256:d2b5255c7c6349bc1bd1e59e08cd12acbbd63ce649f2588755783aa94dfb6b1a \ + --hash=sha256:dacca89f4bfadd5de3d7489b7c8a566eee0d3676333fbb50030263894c38c0dc ssz==0.2.4 \ --hash=sha256:3c944cd97a38448fe2b145d80d704bd28bc3c5368da9624177b0964e37adaf7e \ --hash=sha256:99c4a7bbaf632113fc28beb8770673637286f7fdade1231e0a2c6fae6331c06d diff --git a/staking_deposit/utils/click.py b/staking_deposit/utils/click.py index 85b5b87a..8b9b2ae3 100644 --- a/staking_deposit/utils/click.py +++ b/staking_deposit/utils/click.py @@ -52,9 +52,9 @@ def get_help_record(self, ctx: click.Context) -> Tuple[str, str]: self.help = _value_of(self.callable_help) return super().get_help_record(ctx) - def get_default(self, ctx: click.Context, call: bool = True) -> Any: + def get_default(self, ctx: click.Context) -> Any: self.default = _value_of(self.callable_default) - return super().get_default(ctx, call) + return super().get_default(ctx) def jit_option(*args: Any, **kwargs: Any) -> Callable[[Any], Any]: From 78ae263e35275fef0a7d4b8f664855fc5988bc95 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 19:55:39 +0100 Subject: [PATCH 06/56] try upgrade circleCI to >python3.8 and probably break everything --- .circleci/config.yml | 52 ++++++++++++------------- README.md | 10 ++--- build_configs/linux/requirements.txt | 2 +- build_configs/macos/requirements.txt | 2 +- build_configs/windows/requirements.txt | 2 +- requirements_test.txt | 2 +- setup.py | 2 +- staking_deposit/intl/ar/deposit.json | 2 +- staking_deposit/intl/el/deposit.json | 2 +- staking_deposit/intl/en/deposit.json | 2 +- staking_deposit/intl/fr/deposit.json | 2 +- staking_deposit/intl/id/deposit.json | 2 +- staking_deposit/intl/it/deposit.json | 2 +- staking_deposit/intl/ja/deposit.json | 2 +- staking_deposit/intl/ko/deposit.json | 2 +- staking_deposit/intl/pt-BR/deposit.json | 2 +- staking_deposit/intl/ro/deposit.json | 2 +- staking_deposit/intl/zh-CN/deposit.json | 2 +- tox.ini | 14 +++---- 19 files changed, 53 insertions(+), 55 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 0e9cb4d7..d8536c74 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -25,7 +25,7 @@ jobs: # Job(s) with Linux OS venv_build: docker: - - image: circleci/python:3.8 + - image: cimg/python:3.10 working_directory: ~/repo steps: - checkout @@ -40,7 +40,7 @@ jobs: - ./venv venv_pytest: docker: - - image: circleci/python:3.8 + - image: cimg/python:3.10 working_directory: ~/repo steps: - checkout @@ -56,7 +56,7 @@ jobs: path: test-reports/ venv_lint: docker: - - image: circleci/python:3.8 + - image: cimg/python:3.10 working_directory: ~/repo steps: - checkout @@ -65,35 +65,34 @@ jobs: - run: name: Run linter with venv command: make venv_lint - tox-py37-core: + tox-py310-core: <<: *tox_common docker: - - image: circleci/python:3.7 + - image: cimg/python:3.10 environment: - TOXENV: py37-core + TOXENV: py310-core tox-py38-core: <<: *tox_common docker: - - image: circleci/python:3.8 + - image: cimg/python:3.8 environment: TOXENV: py38-core - tox-py37-script: + tox-py310-script: <<: *tox_common docker: - - image: circleci/python:3.7 + - image: cimg/python:3.10 environment: - TOXENV: py37-script + TOXENV: py310-script tox-py38-script: <<: *tox_common docker: - - image: circleci/python:3.8 + - image: cimg/python:3.8 environment: TOXENV: py38-script # Job(s) with Windows OS - win-py37-script: - executor: - name: win/default - shell: powershell.exe + win-py310-script: + machine: + image: windows-server-2022-vs2022 steps: - checkout - run: @@ -111,8 +110,8 @@ jobs: - run: name: Install building requirements on Linux command: | - env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.7.5; - pyenv global 3.7.5; + env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.8.13; + pyenv global 3.8.13; pip install -r ./build_configs/linux/requirements.txt; - run: name: Build with build.spec @@ -121,7 +120,7 @@ jobs: export CIRCLE_SHORT_SHA1=$(eval echo $CIRCLE_SHA1 | cut -c -7) export BUILD_FILE_NAME=staking_deposit-cli-${CIRCLE_SHORT_SHA1}-linux-amd64; mkdir ${BUILD_FILE_NAME}; - pyenv global 3.7.5; + pyenv global 3.8.13; pyinstaller --distpath ./${BUILD_FILE_NAME} ./build_configs/linux/build.spec; - run: name: Test executable binaries @@ -157,8 +156,8 @@ jobs: - run: name: Install building requirements on Linux ARM64 command: | - env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.7.5; - pyenv global 3.7.5; + env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.8.13; + pyenv global 3.8.13; pip install -r ./build_configs/linux/requirements.txt; - run: name: Build with build.spec @@ -167,7 +166,7 @@ jobs: export CIRCLE_SHORT_SHA1=$(eval echo $CIRCLE_SHA1 | cut -c -7) export BUILD_FILE_NAME=staking_deposit-cli-${CIRCLE_SHORT_SHA1}-linux-arm64; mkdir ${BUILD_FILE_NAME}; - pyenv global 3.7.5; + pyenv global 3.8.13; pyinstaller --distpath ./${BUILD_FILE_NAME} ./build_configs/linux/build.spec; - run: name: Test executable binaries @@ -193,9 +192,8 @@ jobs: - store_artifacts: path: /tmp/artifacts build-windows: - executor: - name: win/default - shell: powershell.exe + machine: + image: windows-server-2022-vs2022 steps: - checkout - run: @@ -292,11 +290,11 @@ workflows: - venv_lint: requires: - venv_build - - tox-py37-core + - tox-py310-core - tox-py38-core - - tox-py37-script + - tox-py310-script - tox-py38-script - - win-py37-script + - win-py310-script build_linux: jobs: - build-linux-amd64 diff --git a/README.md b/README.md index e8ed83ef..f8574889 100644 --- a/README.md +++ b/README.md @@ -81,7 +81,7 @@ You can find the audit report by Trail of Bits [here](https://github.com/trailof ### Build requirements -- [Python **3.7+**](https://www.python.org/about/gettingstarted/) +- [Python **3.8+**](https://www.python.org/about/gettingstarted/) - [pip3](https://pip.pypa.io/en/stable/installing/) ### For Linux or MacOS users @@ -170,7 +170,7 @@ Your keys can be found at: ##### Step 0. Python version checking -Ensure you are using Python version >= Python3.7: +Ensure you are using Python version >= Python3.8: ```sh python3 -V @@ -234,7 +234,7 @@ See [here](#successful-message) ##### Step 0. Python version checking -Ensure you are using Python version >= Python3.7: +Ensure you are using Python version >= Python3.8: ```sh python3 -V @@ -381,7 +381,7 @@ See [here](#existing-mnemonic-arguments) for `existing-mnemonic` arguments ##### Step 0. Python version checking -Ensure you are using Python version >= Python3.7 (Assume that you've installed Python 3 as the main Python): +Ensure you are using Python version >= Python3.8 (Assume that you've installed Python 3 as the main Python): ```sh python -V @@ -443,7 +443,7 @@ See [here](#existing-mnemonic-arguments) for `existing-mnemonic` arguments ##### Step 0. Python version checking -Ensure you are using Python version >= Python3.7 (Assume that you've installed Python 3 as the main Python): +Ensure you are using Python version >= Python3.8 (Assume that you've installed Python 3 as the main Python): ```cmd python -V diff --git a/build_configs/linux/requirements.txt b/build_configs/linux/requirements.txt index bd943ea1..ee6617f0 100644 --- a/build_configs/linux/requirements.txt +++ b/build_configs/linux/requirements.txt @@ -83,7 +83,7 @@ pyinstaller-hooks-contrib==2022.2 \ importlib-metadata==4.11.3 \ --hash=sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6 \ --hash=sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539 -zipp==3.7.0 \ +zipp==3.8.0 \ --hash=sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d \ --hash=sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375 typing-extensions==4.1.1 \ diff --git a/build_configs/macos/requirements.txt b/build_configs/macos/requirements.txt index bd943ea1..ee6617f0 100644 --- a/build_configs/macos/requirements.txt +++ b/build_configs/macos/requirements.txt @@ -83,7 +83,7 @@ pyinstaller-hooks-contrib==2022.2 \ importlib-metadata==4.11.3 \ --hash=sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6 \ --hash=sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539 -zipp==3.7.0 \ +zipp==3.8.0 \ --hash=sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d \ --hash=sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375 typing-extensions==4.1.1 \ diff --git a/build_configs/windows/requirements.txt b/build_configs/windows/requirements.txt index 7bf22250..303ab260 100644 --- a/build_configs/windows/requirements.txt +++ b/build_configs/windows/requirements.txt @@ -101,7 +101,7 @@ pyinstaller-hooks-contrib==2022.2 \ importlib-metadata==4.11.3 \ --hash=sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6 \ --hash=sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539 -zipp==3.7.0 \ +zipp==3.8.0 \ --hash=sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d \ --hash=sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375 typing-extensions==4.1.1 \ diff --git a/requirements_test.txt b/requirements_test.txt index 0a4f031f..3c5f48e1 100644 --- a/requirements_test.txt +++ b/requirements_test.txt @@ -93,7 +93,7 @@ more-itertools==8.12.0 \ py==1.11.0 \ --hash=sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719 \ --hash=sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378 -zipp==3.7.0 \ +zipp==3.8.0 \ --hash=sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d \ --hash=sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375 pyparsing==3.0.7 \ diff --git a/setup.py b/setup.py index ce61b704..d14ea157 100644 --- a/setup.py +++ b/setup.py @@ -9,5 +9,5 @@ version='2.0.0', py_modules=["staking_deposit"], packages=find_packages(exclude=('tests', 'docs')), - python_requires=">=3.7,<4", + python_requires=">=3.8,<4", ) diff --git a/staking_deposit/intl/ar/deposit.json b/staking_deposit/intl/ar/deposit.json index cc30c9ff..45136718 100644 --- a/staking_deposit/intl/ar/deposit.json +++ b/staking_deposit/intl/ar/deposit.json @@ -1,5 +1,5 @@ { "check_python_version": { - "err_python_version": "إصدار بايثون الخاص بك غير كافٍ، يرجى تثبيت الإصدار 3.7 أو الأحدث." + "err_python_version": "إصدار بايثون الخاص بك غير كافٍ، يرجى تثبيت الإصدار 3.8 أو الأحدث." } } \ No newline at end of file diff --git a/staking_deposit/intl/el/deposit.json b/staking_deposit/intl/el/deposit.json index 32ebca25..42858841 100644 --- a/staking_deposit/intl/el/deposit.json +++ b/staking_deposit/intl/el/deposit.json @@ -1,5 +1,5 @@ { "check_python_version": { - "err_python_version": "Η έκδοση python σας δεν είναι επαρκής, εγκαταστήστε την έκδοση 3.7 ή μεγαλύτερη." + "err_python_version": "Η έκδοση python σας δεν είναι επαρκής, εγκαταστήστε την έκδοση 3.8 ή μεγαλύτερη." } } \ No newline at end of file diff --git a/staking_deposit/intl/en/deposit.json b/staking_deposit/intl/en/deposit.json index 39755c08..5af17d1a 100644 --- a/staking_deposit/intl/en/deposit.json +++ b/staking_deposit/intl/en/deposit.json @@ -1,5 +1,5 @@ { "check_python_version": { - "err_python_version": "Your python version is insufficient, please install version 3.7 or greater." + "err_python_version": "Your python version is insufficient, please install version 3.8 or greater." } } \ No newline at end of file diff --git a/staking_deposit/intl/fr/deposit.json b/staking_deposit/intl/fr/deposit.json index 24220bdc..914f4082 100644 --- a/staking_deposit/intl/fr/deposit.json +++ b/staking_deposit/intl/fr/deposit.json @@ -1,5 +1,5 @@ { "check_python_version": { - "err_python_version": "Votre version de Python est insuffisante. Veuillez installer la version 3.7 ou supérieure." + "err_python_version": "Votre version de Python est insuffisante. Veuillez installer la version 3.8 ou supérieure." } } \ No newline at end of file diff --git a/staking_deposit/intl/id/deposit.json b/staking_deposit/intl/id/deposit.json index 9f4979d2..b1dc399a 100644 --- a/staking_deposit/intl/id/deposit.json +++ b/staking_deposit/intl/id/deposit.json @@ -1,5 +1,5 @@ { "check_python_version": { - "err_python_version": "Versi python Anda tidak cukup, harap instal versi 3.7 atau yang lebih baru." + "err_python_version": "Versi python Anda tidak cukup, harap instal versi 3.8 atau yang lebih baru." } } \ No newline at end of file diff --git a/staking_deposit/intl/it/deposit.json b/staking_deposit/intl/it/deposit.json index c892d630..05ee0761 100644 --- a/staking_deposit/intl/it/deposit.json +++ b/staking_deposit/intl/it/deposit.json @@ -1,5 +1,5 @@ { "check_python_version": { - "err_python_version": "La tua versione di python non è sufficiente, installa la versione 3.7 o superiore." + "err_python_version": "La tua versione di python non è sufficiente, installa la versione 3.8 o superiore." } } \ No newline at end of file diff --git a/staking_deposit/intl/ja/deposit.json b/staking_deposit/intl/ja/deposit.json index 1b75d8ad..bdbced67 100644 --- a/staking_deposit/intl/ja/deposit.json +++ b/staking_deposit/intl/ja/deposit.json @@ -1,5 +1,5 @@ { "check_python_version": { - "err_python_version": "Python のバージョンが最新ではありません。バージョン 3.7 以降をインストールしてください。" + "err_python_version": "Python のバージョンが最新ではありません。バージョン 3.8 以降をインストールしてください。" } } \ No newline at end of file diff --git a/staking_deposit/intl/ko/deposit.json b/staking_deposit/intl/ko/deposit.json index 8bb4a274..39ebf7a1 100644 --- a/staking_deposit/intl/ko/deposit.json +++ b/staking_deposit/intl/ko/deposit.json @@ -1,5 +1,5 @@ { "check_python_version": { - "err_python_version": "Python 버전이 너무 낮습니다. 3.7 이상 버전을 설치하세요." + "err_python_version": "Python 버전이 너무 낮습니다. 3.8 이상 버전을 설치하세요." } } \ No newline at end of file diff --git a/staking_deposit/intl/pt-BR/deposit.json b/staking_deposit/intl/pt-BR/deposit.json index 4b2fa17e..bf5bbbdc 100644 --- a/staking_deposit/intl/pt-BR/deposit.json +++ b/staking_deposit/intl/pt-BR/deposit.json @@ -1,5 +1,5 @@ { "check_python_version": { - "err_python_version": "Sua versão do python é insuficiente, por favor instale a versão 3.7 ou superior." + "err_python_version": "Sua versão do python é insuficiente, por favor instale a versão 3.8 ou superior." } } \ No newline at end of file diff --git a/staking_deposit/intl/ro/deposit.json b/staking_deposit/intl/ro/deposit.json index 991b5070..c592697b 100644 --- a/staking_deposit/intl/ro/deposit.json +++ b/staking_deposit/intl/ro/deposit.json @@ -1,5 +1,5 @@ { "check_python_version": { - "err_python_version": "Versiunea de python este prea veche, te rugăm să instalezi versiunea 3.7 sau una mai recentă." + "err_python_version": "Versiunea de python este prea veche, te rugăm să instalezi versiunea 3.8 sau una mai recentă." } } \ No newline at end of file diff --git a/staking_deposit/intl/zh-CN/deposit.json b/staking_deposit/intl/zh-CN/deposit.json index 6d8766e2..ae98045d 100644 --- a/staking_deposit/intl/zh-CN/deposit.json +++ b/staking_deposit/intl/zh-CN/deposit.json @@ -1,5 +1,5 @@ { "check_python_version": { - "err_python_version": "您的 python 版本不足,请安装 3.7 或以上版本。" + "err_python_version": "您的 python 版本不足,请安装 3.8 或以上版本。" } } \ No newline at end of file diff --git a/tox.ini b/tox.ini index 69858060..85356efe 100644 --- a/tox.ini +++ b/tox.ini @@ -1,14 +1,14 @@ [tox] envlist= - py{37,38}-core - py{37,38}-lint - py{37,38}-script + py{310,38}-core + py{310,38}-lint + py{310,38}-script [testenv] passenv= PYTEST_ADDOPTS basepython= - py37: python3.7 + py310: python3.10 py38: python3.8 [common-install] @@ -33,7 +33,7 @@ deps= commands= python {toxinidir}/test_deposit_script.py -[testenv:py37-core] +[testenv:py310-core] deps={[common-core]deps} commands={[common-core]commands} @@ -41,7 +41,7 @@ commands={[common-core]commands} deps={[common-core]deps} commands={[common-core]commands} -[testenv:py37-lint] +[testenv:py310-lint] deps={[common-lint]deps} commands={[common-lint]commands} @@ -49,7 +49,7 @@ commands={[common-lint]commands} deps={[common-lint]deps} commands={[common-lint]commands} -[testenv:py37-script] +[testenv:py310-script] deps={[common-script]deps} commands={[common-script]commands} From 7ce367fa025d4a0803a1ef532881f77b7d904767 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 20:04:29 +0100 Subject: [PATCH 07/56] =?UTF-8?q?revert=20zipp=20version=20becuase=20i=20o?= =?UTF-8?q?ver-used=20find-and-replace=20=F0=9F=A4=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- build_configs/linux/requirements.txt | 2 +- build_configs/macos/requirements.txt | 2 +- build_configs/windows/requirements.txt | 2 +- requirements_test.txt | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/build_configs/linux/requirements.txt b/build_configs/linux/requirements.txt index ee6617f0..bd943ea1 100644 --- a/build_configs/linux/requirements.txt +++ b/build_configs/linux/requirements.txt @@ -83,7 +83,7 @@ pyinstaller-hooks-contrib==2022.2 \ importlib-metadata==4.11.3 \ --hash=sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6 \ --hash=sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539 -zipp==3.8.0 \ +zipp==3.7.0 \ --hash=sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d \ --hash=sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375 typing-extensions==4.1.1 \ diff --git a/build_configs/macos/requirements.txt b/build_configs/macos/requirements.txt index ee6617f0..bd943ea1 100644 --- a/build_configs/macos/requirements.txt +++ b/build_configs/macos/requirements.txt @@ -83,7 +83,7 @@ pyinstaller-hooks-contrib==2022.2 \ importlib-metadata==4.11.3 \ --hash=sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6 \ --hash=sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539 -zipp==3.8.0 \ +zipp==3.7.0 \ --hash=sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d \ --hash=sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375 typing-extensions==4.1.1 \ diff --git a/build_configs/windows/requirements.txt b/build_configs/windows/requirements.txt index 303ab260..7bf22250 100644 --- a/build_configs/windows/requirements.txt +++ b/build_configs/windows/requirements.txt @@ -101,7 +101,7 @@ pyinstaller-hooks-contrib==2022.2 \ importlib-metadata==4.11.3 \ --hash=sha256:1208431ca90a8cca1a6b8af391bb53c1a2db74e5d1cef6ddced95d4b2062edc6 \ --hash=sha256:ea4c597ebf37142f827b8f39299579e31685c31d3a438b59f469406afd0f2539 -zipp==3.8.0 \ +zipp==3.7.0 \ --hash=sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d \ --hash=sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375 typing-extensions==4.1.1 \ diff --git a/requirements_test.txt b/requirements_test.txt index 3c5f48e1..0a4f031f 100644 --- a/requirements_test.txt +++ b/requirements_test.txt @@ -93,7 +93,7 @@ more-itertools==8.12.0 \ py==1.11.0 \ --hash=sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719 \ --hash=sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378 -zipp==3.8.0 \ +zipp==3.7.0 \ --hash=sha256:9f50f446828eb9d45b267433fd3e9da8d801f614129124863f9c51ebceafb87d \ --hash=sha256:b47250dd24f92b7dd6a0a8fc5244da14608f3ca90a5efcd37a3b1642fac9a375 pyparsing==3.0.7 \ From e82b3e3a9733223f57ace00061d01ce050ffd11f Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 20:05:28 +0100 Subject: [PATCH 08/56] Updates windows server version to edge --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index d8536c74..c8d8406d 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -92,7 +92,7 @@ jobs: # Job(s) with Windows OS win-py310-script: machine: - image: windows-server-2022-vs2022 + image: windows-server-2022-vs2022:edge steps: - checkout - run: @@ -193,7 +193,7 @@ jobs: path: /tmp/artifacts build-windows: machine: - image: windows-server-2022-vs2022 + image: windows-server-2022-vs2022:edge steps: - checkout - run: From e829e943b6adb94f55c83b7aa9a1b8d6283511e9 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 20:24:15 +0100 Subject: [PATCH 09/56] update pyenv python versions for arm --- .circleci/config.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index c8d8406d..ad35cd47 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -110,8 +110,8 @@ jobs: - run: name: Install building requirements on Linux command: | - env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.8.13; - pyenv global 3.8.13; + env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.10.3; + pyenv global 3.10.3; pip install -r ./build_configs/linux/requirements.txt; - run: name: Build with build.spec @@ -120,7 +120,7 @@ jobs: export CIRCLE_SHORT_SHA1=$(eval echo $CIRCLE_SHA1 | cut -c -7) export BUILD_FILE_NAME=staking_deposit-cli-${CIRCLE_SHORT_SHA1}-linux-amd64; mkdir ${BUILD_FILE_NAME}; - pyenv global 3.8.13; + pyenv global 3.10.3; pyinstaller --distpath ./${BUILD_FILE_NAME} ./build_configs/linux/build.spec; - run: name: Test executable binaries @@ -156,8 +156,8 @@ jobs: - run: name: Install building requirements on Linux ARM64 command: | - env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.8.13; - pyenv global 3.8.13; + env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.8.12; + pyenv global 3.8.12; pip install -r ./build_configs/linux/requirements.txt; - run: name: Build with build.spec @@ -166,7 +166,7 @@ jobs: export CIRCLE_SHORT_SHA1=$(eval echo $CIRCLE_SHA1 | cut -c -7) export BUILD_FILE_NAME=staking_deposit-cli-${CIRCLE_SHORT_SHA1}-linux-arm64; mkdir ${BUILD_FILE_NAME}; - pyenv global 3.8.13; + pyenv global 3.10.3; pyinstaller --distpath ./${BUILD_FILE_NAME} ./build_configs/linux/build.spec; - run: name: Test executable binaries From c10e0e4a62d3414247d67ffe1bba5ea1f58b3129 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 20:25:18 +0100 Subject: [PATCH 10/56] update sundry python version references --- Dockerfile | 2 +- README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 73039d74..265ebf55 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM python:3.7-alpine +FROM python:alpine3.14 WORKDIR /app diff --git a/README.md b/README.md index f8574889..54338b1d 100644 --- a/README.md +++ b/README.md @@ -531,5 +531,5 @@ python3 -m pytest . 👋This is not the section you are looking for.👋 If you are trying to **build the binary** on macos with an M1 Mac and you are using pyenv to manage your python version. You'll probably need to reinstall a given python version using: ``` -env PYTHON_CONFIGURE_OPTS="--enable-framework" pyenv install 3.10.2 +env PYTHON_CONFIGURE_OPTS="--enable-framework" pyenv install 3.10.3 ``` From d2ed76819d3d2c9c24d1897cf59fd3dba7f1f9ea Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 21:06:37 +0100 Subject: [PATCH 11/56] upgrade windows machince reasources --- .circleci/config.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index ad35cd47..b35fb98d 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -93,6 +93,7 @@ jobs: win-py310-script: machine: image: windows-server-2022-vs2022:edge + resource_class: large steps: - checkout - run: @@ -194,6 +195,7 @@ jobs: build-windows: machine: image: windows-server-2022-vs2022:edge + resource_class: medium+ steps: - checkout - run: From c59c5180d9d83e9d4fbca3f6b002dff39cdc08a2 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 21:09:49 +0100 Subject: [PATCH 12/56] Add in missing python version stuffies --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index b35fb98d..902a132b 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -157,8 +157,8 @@ jobs: - run: name: Install building requirements on Linux ARM64 command: | - env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.8.12; - pyenv global 3.8.12; + env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.10.3; + pyenv global 3.10.3; pip install -r ./build_configs/linux/requirements.txt; - run: name: Build with build.spec From 712002c9546511dc0b7b8d9ea31a126ec2017f9d Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 21:12:45 +0100 Subject: [PATCH 13/56] revert to old windows version --- .circleci/config.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 902a132b..25485c06 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -91,9 +91,9 @@ jobs: TOXENV: py38-script # Job(s) with Windows OS win-py310-script: - machine: - image: windows-server-2022-vs2022:edge - resource_class: large + executor: + name: win/default + shell: powershell.exe steps: - checkout - run: @@ -193,9 +193,9 @@ jobs: - store_artifacts: path: /tmp/artifacts build-windows: - machine: - image: windows-server-2022-vs2022:edge - resource_class: medium+ + executor: + name: win/default + shell: powershell.exe steps: - checkout - run: From ec1b6416d3485e6d9627cd219345c397ceb9d658 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 21:17:08 +0100 Subject: [PATCH 14/56] installes python 3.10 for windows --- .circleci/config.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 25485c06..b41433c8 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -96,6 +96,9 @@ jobs: shell: powershell.exe steps: - checkout + - run: + name: "Install Python" + command: choco install python --version=3.10.3 - run: name: Install testing requirements on Windows command: python -m pip install -r requirements_test.txt @@ -198,6 +201,9 @@ jobs: shell: powershell.exe steps: - checkout + - run: + name: "Install Python" + command: choco install python --version=3.10.3 - run: name: Install building requirements on Windows command: pip install -r ./build_configs/windows/requirements.txt From 513d2818db496b1f508547cd28fe47e8fa76b973 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 21:35:31 +0100 Subject: [PATCH 15/56] use python 3.10.2 for linux amd64 --- .circleci/config.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index b41433c8..fb136bea 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -114,8 +114,8 @@ jobs: - run: name: Install building requirements on Linux command: | - env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.10.3; - pyenv global 3.10.3; + env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.10.2; + pyenv global 3.10.2; pip install -r ./build_configs/linux/requirements.txt; - run: name: Build with build.spec @@ -124,7 +124,7 @@ jobs: export CIRCLE_SHORT_SHA1=$(eval echo $CIRCLE_SHA1 | cut -c -7) export BUILD_FILE_NAME=staking_deposit-cli-${CIRCLE_SHORT_SHA1}-linux-amd64; mkdir ${BUILD_FILE_NAME}; - pyenv global 3.10.3; + pyenv global 3.10.2; pyinstaller --distpath ./${BUILD_FILE_NAME} ./build_configs/linux/build.spec; - run: name: Test executable binaries @@ -160,8 +160,8 @@ jobs: - run: name: Install building requirements on Linux ARM64 command: | - env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.10.3; - pyenv global 3.10.3; + env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.10.2; + pyenv global 3.10.2; pip install -r ./build_configs/linux/requirements.txt; - run: name: Build with build.spec @@ -170,7 +170,7 @@ jobs: export CIRCLE_SHORT_SHA1=$(eval echo $CIRCLE_SHA1 | cut -c -7) export BUILD_FILE_NAME=staking_deposit-cli-${CIRCLE_SHORT_SHA1}-linux-arm64; mkdir ${BUILD_FILE_NAME}; - pyenv global 3.10.3; + pyenv global 3.10.2; pyinstaller --distpath ./${BUILD_FILE_NAME} ./build_configs/linux/build.spec; - run: name: Test executable binaries From 76b7b3c21da962589c06a9f65a2ab01cca7c57b8 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 21:39:44 +0100 Subject: [PATCH 16/56] update to current ubuntu images --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index fb136bea..4b50ecd0 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -107,7 +107,7 @@ jobs: command: python ./test_deposit_script.py build-linux-amd64: machine: - image: ubuntu-1604:202007-01 + image: ubuntu-2004:current working_directory: ~/repo steps: - checkout @@ -152,7 +152,7 @@ jobs: path: /tmp/artifacts build-linux-arm64: machine: - image: ubuntu-2004:202101-01 + image: ubuntu-2004:current resource_class: arm.medium working_directory: ~/repo steps: From 07ed5a268f6cc1847eeb83df1a80f28ea06992dc Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 21:54:47 +0100 Subject: [PATCH 17/56] allow pyenv to skip version warning --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 4b50ecd0..5fc34475 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -114,7 +114,7 @@ jobs: - run: name: Install building requirements on Linux command: | - env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.10.2; + env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install -s 3.10.2; pyenv global 3.10.2; pip install -r ./build_configs/linux/requirements.txt; - run: @@ -160,7 +160,7 @@ jobs: - run: name: Install building requirements on Linux ARM64 command: | - env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.10.2; + env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install -s 3.10.2; pyenv global 3.10.2; pip install -r ./build_configs/linux/requirements.txt; - run: From 72c8a0fa9c9eec398fc4b3c7724296262bb7c951 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 21:55:36 +0100 Subject: [PATCH 18/56] lock ubuntu version --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 5fc34475..c2b9287e 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -107,7 +107,7 @@ jobs: command: python ./test_deposit_script.py build-linux-amd64: machine: - image: ubuntu-2004:current + image: ubuntu-2004:202201-02 working_directory: ~/repo steps: - checkout @@ -152,7 +152,7 @@ jobs: path: /tmp/artifacts build-linux-arm64: machine: - image: ubuntu-2004:current + image: ubuntu-2004:202201-02 resource_class: arm.medium working_directory: ~/repo steps: From d5cd39aa60c1c2f410066201af18177b0616b380 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 22:06:52 +0100 Subject: [PATCH 19/56] force install using pyenv --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index c2b9287e..bf143bac 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -114,7 +114,7 @@ jobs: - run: name: Install building requirements on Linux command: | - env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install -s 3.10.2; + env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install -f 3.10.2; pyenv global 3.10.2; pip install -r ./build_configs/linux/requirements.txt; - run: @@ -160,7 +160,7 @@ jobs: - run: name: Install building requirements on Linux ARM64 command: | - env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install -s 3.10.2; + env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install -f 3.10.2; pyenv global 3.10.2; pip install -r ./build_configs/linux/requirements.txt; - run: From 3f97a0ecda325ebf5aea670b36673635e2c42103 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 22:07:41 +0100 Subject: [PATCH 20/56] try 3.10.3 for ubuntu again --- .circleci/config.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index bf143bac..13d221b6 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -114,8 +114,8 @@ jobs: - run: name: Install building requirements on Linux command: | - env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install -f 3.10.2; - pyenv global 3.10.2; + env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install -f 3.10.3; + pyenv global 3.10.3; pip install -r ./build_configs/linux/requirements.txt; - run: name: Build with build.spec @@ -124,7 +124,7 @@ jobs: export CIRCLE_SHORT_SHA1=$(eval echo $CIRCLE_SHA1 | cut -c -7) export BUILD_FILE_NAME=staking_deposit-cli-${CIRCLE_SHORT_SHA1}-linux-amd64; mkdir ${BUILD_FILE_NAME}; - pyenv global 3.10.2; + pyenv global 3.10.3; pyinstaller --distpath ./${BUILD_FILE_NAME} ./build_configs/linux/build.spec; - run: name: Test executable binaries @@ -160,8 +160,8 @@ jobs: - run: name: Install building requirements on Linux ARM64 command: | - env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install -f 3.10.2; - pyenv global 3.10.2; + env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install -f 3.10.3; + pyenv global 3.10.3; pip install -r ./build_configs/linux/requirements.txt; - run: name: Build with build.spec @@ -170,7 +170,7 @@ jobs: export CIRCLE_SHORT_SHA1=$(eval echo $CIRCLE_SHA1 | cut -c -7) export BUILD_FILE_NAME=staking_deposit-cli-${CIRCLE_SHORT_SHA1}-linux-arm64; mkdir ${BUILD_FILE_NAME}; - pyenv global 3.10.2; + pyenv global 3.10.3; pyinstaller --distpath ./${BUILD_FILE_NAME} ./build_configs/linux/build.spec; - run: name: Test executable binaries From e91a27d7c252d45d22fb50cd50c580192af02afd Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 21 Mar 2022 22:12:45 +0100 Subject: [PATCH 21/56] revert to 3.10.2 for ubuntu again --- .circleci/config.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 13d221b6..bf143bac 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -114,8 +114,8 @@ jobs: - run: name: Install building requirements on Linux command: | - env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install -f 3.10.3; - pyenv global 3.10.3; + env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install -f 3.10.2; + pyenv global 3.10.2; pip install -r ./build_configs/linux/requirements.txt; - run: name: Build with build.spec @@ -124,7 +124,7 @@ jobs: export CIRCLE_SHORT_SHA1=$(eval echo $CIRCLE_SHA1 | cut -c -7) export BUILD_FILE_NAME=staking_deposit-cli-${CIRCLE_SHORT_SHA1}-linux-amd64; mkdir ${BUILD_FILE_NAME}; - pyenv global 3.10.3; + pyenv global 3.10.2; pyinstaller --distpath ./${BUILD_FILE_NAME} ./build_configs/linux/build.spec; - run: name: Test executable binaries @@ -160,8 +160,8 @@ jobs: - run: name: Install building requirements on Linux ARM64 command: | - env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install -f 3.10.3; - pyenv global 3.10.3; + env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install -f 3.10.2; + pyenv global 3.10.2; pip install -r ./build_configs/linux/requirements.txt; - run: name: Build with build.spec @@ -170,7 +170,7 @@ jobs: export CIRCLE_SHORT_SHA1=$(eval echo $CIRCLE_SHA1 | cut -c -7) export BUILD_FILE_NAME=staking_deposit-cli-${CIRCLE_SHORT_SHA1}-linux-arm64; mkdir ${BUILD_FILE_NAME}; - pyenv global 3.10.3; + pyenv global 3.10.2; pyinstaller --distpath ./${BUILD_FILE_NAME} ./build_configs/linux/build.spec; - run: name: Test executable binaries From fb5ffe64e6cb00a68ad5bc9c8f813b6bdf72e0a7 Mon Sep 17 00:00:00 2001 From: Thorsten Behrens Date: Sat, 5 Feb 2022 14:21:26 +0000 Subject: [PATCH 22/56] Allow 4-character abbreviations of mnemonic words --- staking_deposit/cli/existing_mnemonic.py | 3 +- .../key_handling/key_derivation/mnemonic.py | 28 +++++++++++-------- .../test_key_derivation/test_mnemonic.py | 8 +++--- 3 files changed, 23 insertions(+), 16 deletions(-) diff --git a/staking_deposit/cli/existing_mnemonic.py b/staking_deposit/cli/existing_mnemonic.py index 98e8bcd4..6ded63ae 100644 --- a/staking_deposit/cli/existing_mnemonic.py +++ b/staking_deposit/cli/existing_mnemonic.py @@ -23,7 +23,8 @@ def validate_mnemonic(ctx: click.Context, param: Any, mnemonic: str) -> str: - if verify_mnemonic(mnemonic, WORD_LISTS_PATH): + mnemonic = verify_mnemonic(mnemonic, WORD_LISTS_PATH) + if mnemonic is not None: return mnemonic else: raise ValidationError(load_text(['err_invalid_mnemonic'])) diff --git a/staking_deposit/key_handling/key_derivation/mnemonic.py b/staking_deposit/key_handling/key_derivation/mnemonic.py index c93c37f4..3c81a701 100644 --- a/staking_deposit/key_handling/key_derivation/mnemonic.py +++ b/staking_deposit/key_handling/key_derivation/mnemonic.py @@ -68,9 +68,10 @@ def determine_mnemonic_language(mnemonic: str, words_path: str) -> Sequence[str] languages = MNEMONIC_LANG_OPTIONS.keys() word_language_map = {word: lang for lang in languages for word in _get_word_list(lang, words_path)} try: - mnemonic_list = mnemonic.split(' ') - word_languages = [word_language_map[word] for word in mnemonic_list] - return list(set(word_languages)) + mnemonic_list = [normalize('NFKC', word)[:4] for word in mnemonic.lower().split(' ')] + word_languages = [[lang for word, lang in word_language_map.items() if normalize('NFKC', word)[:4] == abbrev] + for abbrev in mnemonic_list] + return list(set(sum(word_languages, []))) except KeyError: raise ValueError('Word not found in mnemonic word lists for any language.') @@ -90,30 +91,35 @@ def _get_checksum(entropy: bytes) -> int: return int.from_bytes(SHA256(entropy), 'big') >> (256 - checksum_length) -def verify_mnemonic(mnemonic: str, words_path: str) -> bool: +def verify_mnemonic(mnemonic: str, words_path: str) -> str: """ - Given a mnemonic, verify it against its own checksum." + Given a mnemonic, verify it against its own checksum and return + a reconstructed full version - useful in case it was abbreviated. """ try: languages = determine_mnemonic_language(mnemonic, words_path) except ValueError: - return False + return None for language in languages: try: - word_list = _get_word_list(language, words_path) - mnemonic_list = mnemonic.split(' ') + word_list = [normalize('NFKC', word)[:4] for word in _get_word_list(language, words_path)] + mnemonic_list = [normalize('NFKC', word)[:4] for word in mnemonic.lower().split(' ')] if len(mnemonic_list) not in range(12, 25, 3): - return False + return None word_indices = [_word_to_index(word_list, word) for word in mnemonic_list] mnemonic_int = _uint11_array_to_uint(word_indices) checksum_length = len(mnemonic_list) // 3 checksum = mnemonic_int & 2**checksum_length - 1 entropy = (mnemonic_int - checksum) >> checksum_length entropy_bits = entropy.to_bytes(checksum_length * 4, 'big') - return _get_checksum(entropy_bits) == checksum + full_word_list = _get_word_list(language, words_path) + if _get_checksum(entropy_bits) == checksum: + return ' '.join([_index_to_word(full_word_list, index) for index in word_indices]) + else: + pass except ValueError: pass - return False + return None def get_mnemonic(*, language: str, words_path: str, entropy: Optional[bytes]=None) -> str: diff --git a/tests/test_key_handling/test_key_derivation/test_mnemonic.py b/tests/test_key_handling/test_key_derivation/test_mnemonic.py index a913e391..ab543c2f 100644 --- a/tests/test_key_handling/test_key_derivation/test_mnemonic.py +++ b/tests/test_key_handling/test_key_derivation/test_mnemonic.py @@ -40,13 +40,13 @@ def test_bip39(language: str, test: Sequence[str]) -> None: @pytest.mark.parametrize( - 'test_mnemonic,is_valid', - [(test_mnemonic[1], True) + 'test_mnemonic', + [(test_mnemonic[1]) for _, language_test_vectors in test_vectors.items() for test_mnemonic in language_test_vectors] ) -def test_verify_mnemonic(test_mnemonic: str, is_valid: bool) -> None: - assert verify_mnemonic(test_mnemonic, WORD_LISTS_PATH) == is_valid +def test_verify_mnemonic(test_mnemonic: str) -> None: + assert verify_mnemonic(test_mnemonic, WORD_LISTS_PATH) is not None @pytest.mark.parametrize( From 5953f30cd6ffb687c4dc2d147da61d2a34221ae9 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Thu, 24 Mar 2022 12:46:32 +0100 Subject: [PATCH 23/56] abbreviation tweaks --- staking_deposit/cli/existing_mnemonic.py | 4 ++-- staking_deposit/intl/en/cli/existing_mnemonic.json | 2 +- staking_deposit/intl/en/cli/new_mnemonic.json | 2 +- staking_deposit/key_handling/key_derivation/mnemonic.py | 6 +++--- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/staking_deposit/cli/existing_mnemonic.py b/staking_deposit/cli/existing_mnemonic.py index 6ded63ae..97e090f6 100644 --- a/staking_deposit/cli/existing_mnemonic.py +++ b/staking_deposit/cli/existing_mnemonic.py @@ -5,7 +5,7 @@ from staking_deposit.exceptions import ValidationError from staking_deposit.key_handling.key_derivation.mnemonic import ( - verify_mnemonic, + reconstruct_mnemonic, ) from staking_deposit.utils.constants import ( WORD_LISTS_PATH, @@ -23,7 +23,7 @@ def validate_mnemonic(ctx: click.Context, param: Any, mnemonic: str) -> str: - mnemonic = verify_mnemonic(mnemonic, WORD_LISTS_PATH) + mnemonic = reconstruct_mnemonic(mnemonic, WORD_LISTS_PATH) if mnemonic is not None: return mnemonic else: diff --git a/staking_deposit/intl/en/cli/existing_mnemonic.json b/staking_deposit/intl/en/cli/existing_mnemonic.json index 9b70c276..4e5b3fbd 100644 --- a/staking_deposit/intl/en/cli/existing_mnemonic.json +++ b/staking_deposit/intl/en/cli/existing_mnemonic.json @@ -8,7 +8,7 @@ }, "arg_mnemonic": { "help": "The mnemonic that you used to generate your keys. (It is recommended not to use this argument, and wait for the CLI to ask you for your mnemonic as otherwise it will appear in your shell history.)", - "prompt": "Please enter your mnemonic separated by spaces (\" \")" + "prompt": "Please enter your mnemonic separated by spaces (\" \"). Note: you only need to enter the first 4 letters of each word." }, "arg_mnemonic_password": { "help": "This is almost certainly not the argument you are looking for: it is for mnemonic passwords, not keystore passwords. Providing a password here when you didn't use one initially, can result in lost keys (and therefore funds)! Also note that if you used this tool to generate your mnemonic initially, then you did not use a mnemonic password. However, if you are certain you used a password to \"increase\" the security of your mnemonic, this is where you enter it.", diff --git a/staking_deposit/intl/en/cli/new_mnemonic.json b/staking_deposit/intl/en/cli/new_mnemonic.json index 2c6d54c3..94d3c126 100644 --- a/staking_deposit/intl/en/cli/new_mnemonic.json +++ b/staking_deposit/intl/en/cli/new_mnemonic.json @@ -10,6 +10,6 @@ }, "msg_mnemonic_presentation": "This is your mnemonic (seed phrase). Write it down and store it safely. It is the ONLY way to retrieve your deposit.", "msg_press_any_key": "Press any key when you have written down your mnemonic.", - "msg_mnemonic_retype_prompt": "Please type your mnemonic (separated by spaces) to confirm you have written it down" + "msg_mnemonic_retype_prompt": "Please type your mnemonic (separated by spaces) to confirm you have written it down. Note: you only need to enter the first 4 letters of each word." } } diff --git a/staking_deposit/key_handling/key_derivation/mnemonic.py b/staking_deposit/key_handling/key_derivation/mnemonic.py index 3c81a701..82ef4bce 100644 --- a/staking_deposit/key_handling/key_derivation/mnemonic.py +++ b/staking_deposit/key_handling/key_derivation/mnemonic.py @@ -91,10 +91,10 @@ def _get_checksum(entropy: bytes) -> int: return int.from_bytes(SHA256(entropy), 'big') >> (256 - checksum_length) -def verify_mnemonic(mnemonic: str, words_path: str) -> str: +def reconstruct_mnemonic(mnemonic: str, words_path: str) -> Optional[str]: """ - Given a mnemonic, verify it against its own checksum and return - a reconstructed full version - useful in case it was abbreviated. + Given a mnemonic, a reconstructed the full version (incase the abbreviated words were used) + then verify it against its own checksum """ try: languages = determine_mnemonic_language(mnemonic, words_path) From 567ae3629515fce0b086f4a681a3f1220ef2bbdf Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Thu, 24 Mar 2022 12:47:11 +0100 Subject: [PATCH 24/56] Adds abbreviation tests --- .../test_key_derivation/test_mnemonic.py | 21 ++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/tests/test_key_handling/test_key_derivation/test_mnemonic.py b/tests/test_key_handling/test_key_derivation/test_mnemonic.py index ab543c2f..04427926 100644 --- a/tests/test_key_handling/test_key_derivation/test_mnemonic.py +++ b/tests/test_key_handling/test_key_derivation/test_mnemonic.py @@ -4,6 +4,7 @@ from typing import ( Sequence, ) +from unicodedata import normalize from staking_deposit.utils.constants import ( MNEMONIC_LANG_OPTIONS, @@ -13,7 +14,7 @@ _get_word_list, get_seed, get_mnemonic, - verify_mnemonic, + reconstruct_mnemonic, ) @@ -45,8 +46,22 @@ def test_bip39(language: str, test: Sequence[str]) -> None: for _, language_test_vectors in test_vectors.items() for test_mnemonic in language_test_vectors] ) -def test_verify_mnemonic(test_mnemonic: str) -> None: - assert verify_mnemonic(test_mnemonic, WORD_LISTS_PATH) is not None +def test_reconstruct_mnemonic(test_mnemonic: str) -> None: + assert reconstruct_mnemonic(test_mnemonic, WORD_LISTS_PATH) is not None + +def abbreviate_mnemonic(mnemonic: str) -> str: + words = str.split(mnemonic) + words = [normalize('NFKC', word) for word in words] + return str.join(' ', words) + +@pytest.mark.parametrize( + 'test_mnemonic', + [abbreviate_mnemonic(test_mnemonic[1]) + for _, language_test_vectors in test_vectors.items() + for test_mnemonic in language_test_vectors] +) +def test_reconstruct_abbreviated_mnemonic(test_mnemonic: str) -> None: + assert reconstruct_mnemonic(test_mnemonic, WORD_LISTS_PATH) is not None @pytest.mark.parametrize( From bbeeb1f439bb21b070f9bf88c1789f4bd73f896c Mon Sep 17 00:00:00 2001 From: Thorsten Behrens Date: Thu, 24 Mar 2022 14:03:32 +0000 Subject: [PATCH 25/56] Fix lint; revert new-mnemonic text change --- staking_deposit/intl/en/cli/new_mnemonic.json | 2 +- tests/test_key_handling/test_key_derivation/test_mnemonic.py | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/staking_deposit/intl/en/cli/new_mnemonic.json b/staking_deposit/intl/en/cli/new_mnemonic.json index 94d3c126..4e6042c5 100644 --- a/staking_deposit/intl/en/cli/new_mnemonic.json +++ b/staking_deposit/intl/en/cli/new_mnemonic.json @@ -10,6 +10,6 @@ }, "msg_mnemonic_presentation": "This is your mnemonic (seed phrase). Write it down and store it safely. It is the ONLY way to retrieve your deposit.", "msg_press_any_key": "Press any key when you have written down your mnemonic.", - "msg_mnemonic_retype_prompt": "Please type your mnemonic (separated by spaces) to confirm you have written it down. Note: you only need to enter the first 4 letters of each word." + "msg_mnemonic_retype_prompt": "Please type your mnemonic (separated by spaces) to confirm you have written it down." } } diff --git a/tests/test_key_handling/test_key_derivation/test_mnemonic.py b/tests/test_key_handling/test_key_derivation/test_mnemonic.py index 04427926..03aaf8b0 100644 --- a/tests/test_key_handling/test_key_derivation/test_mnemonic.py +++ b/tests/test_key_handling/test_key_derivation/test_mnemonic.py @@ -49,11 +49,13 @@ def test_bip39(language: str, test: Sequence[str]) -> None: def test_reconstruct_mnemonic(test_mnemonic: str) -> None: assert reconstruct_mnemonic(test_mnemonic, WORD_LISTS_PATH) is not None + def abbreviate_mnemonic(mnemonic: str) -> str: words = str.split(mnemonic) words = [normalize('NFKC', word) for word in words] return str.join(' ', words) + @pytest.mark.parametrize( 'test_mnemonic', [abbreviate_mnemonic(test_mnemonic[1]) From 202a620a625ee395801e19f8bed57cae6d91ecc9 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 28 Mar 2022 10:54:57 +0200 Subject: [PATCH 26/56] Adds tests for existing mnemonic abbreviated words --- .../intl/en/cli/existing_mnemonic.json | 2 +- .../key_handling/key_derivation/mnemonic.py | 12 ++++- tests/test_cli/test_existing_menmonic.py | 47 +++++++++++++++++++ 3 files changed, 58 insertions(+), 3 deletions(-) diff --git a/staking_deposit/intl/en/cli/existing_mnemonic.json b/staking_deposit/intl/en/cli/existing_mnemonic.json index 4e5b3fbd..af57b5b8 100644 --- a/staking_deposit/intl/en/cli/existing_mnemonic.json +++ b/staking_deposit/intl/en/cli/existing_mnemonic.json @@ -8,7 +8,7 @@ }, "arg_mnemonic": { "help": "The mnemonic that you used to generate your keys. (It is recommended not to use this argument, and wait for the CLI to ask you for your mnemonic as otherwise it will appear in your shell history.)", - "prompt": "Please enter your mnemonic separated by spaces (\" \"). Note: you only need to enter the first 4 letters of each word." + "prompt": "Please enter your mnemonic separated by spaces (\" \"). Note: you only need to enter the first 4 letters of each word if you'd prefer." }, "arg_mnemonic_password": { "help": "This is almost certainly not the argument you are looking for: it is for mnemonic passwords, not keystore passwords. Providing a password here when you didn't use one initially, can result in lost keys (and therefore funds)! Also note that if you used this tool to generate your mnemonic initially, then you did not use a mnemonic password. However, if you are certain you used a password to \"increase\" the security of your mnemonic, this is where you enter it.", diff --git a/staking_deposit/key_handling/key_derivation/mnemonic.py b/staking_deposit/key_handling/key_derivation/mnemonic.py index 82ef4bce..49f5ada1 100644 --- a/staking_deposit/key_handling/key_derivation/mnemonic.py +++ b/staking_deposit/key_handling/key_derivation/mnemonic.py @@ -2,6 +2,7 @@ from unicodedata import normalize from secrets import randbits from typing import ( + List, Optional, Sequence, ) @@ -91,6 +92,13 @@ def _get_checksum(entropy: bytes) -> int: return int.from_bytes(SHA256(entropy), 'big') >> (256 - checksum_length) +def abbreviate_words(words: Sequence[str]) -> List[str]: + """ + Given a series of word strings, return the 4-letter version of each word (which is unique according to BIP39) + """ + return [normalize('NFKC', word)[:4] for word in words] + + def reconstruct_mnemonic(mnemonic: str, words_path: str) -> Optional[str]: """ Given a mnemonic, a reconstructed the full version (incase the abbreviated words were used) @@ -102,8 +110,8 @@ def reconstruct_mnemonic(mnemonic: str, words_path: str) -> Optional[str]: return None for language in languages: try: - word_list = [normalize('NFKC', word)[:4] for word in _get_word_list(language, words_path)] - mnemonic_list = [normalize('NFKC', word)[:4] for word in mnemonic.lower().split(' ')] + word_list = abbreviate_words(_get_word_list(language, words_path)) + mnemonic_list = abbreviate_words(mnemonic.lower().split(' ')) if len(mnemonic_list) not in range(12, 25, 3): return None word_indices = [_word_to_index(word_list, word) for word in mnemonic_list] diff --git a/tests/test_cli/test_existing_menmonic.py b/tests/test_cli/test_existing_menmonic.py index 25e0556d..bcd5a8a1 100644 --- a/tests/test_cli/test_existing_menmonic.py +++ b/tests/test_cli/test_existing_menmonic.py @@ -152,3 +152,50 @@ async def test_script() -> None: # Clean up clean_key_folder(my_folder_path) + + +@pytest.mark.asyncio +async def test_script_abbreviated_mnemonic() -> None: + my_folder_path = os.path.join(os.getcwd(), 'TESTING_TEMP_FOLDER') + if not os.path.exists(my_folder_path): + os.mkdir(my_folder_path) + + if os.name == 'nt': # Windows + run_script_cmd = 'sh deposit.sh' + else: # Mac or Linux + run_script_cmd = './deposit.sh' + + install_cmd = run_script_cmd + ' install' + proc = await asyncio.create_subprocess_shell( + install_cmd, + ) + await proc.wait() + + cmd_args = [ + run_script_cmd, + '--language', 'english', + '--non_interactive', + 'existing-mnemonic', + '--num_validators', '1', + '--mnemonic="aban aban aban aban aban aban aban aban aban aban aban abou"', + '--mnemonic-password', 'TREZOR', + '--validator_start_index', '1', + '--chain', 'mainnet', + '--keystore_password', 'MyPassword', + '--folder', my_folder_path, + ] + proc = await asyncio.create_subprocess_shell( + ' '.join(cmd_args), + ) + await proc.wait() + # Check files + validator_keys_folder_path = os.path.join(my_folder_path, DEFAULT_VALIDATOR_KEYS_FOLDER_NAME) + _, _, key_files = next(os.walk(validator_keys_folder_path)) + + # Verify file permissions + if os.name == 'posix': + for file_name in key_files: + assert get_permissions(validator_keys_folder_path, file_name) == '0o440' + + # Clean up + clean_key_folder(my_folder_path) From 885826c5262545c28d84c7e21f8a34d95fae25ed Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 28 Mar 2022 10:57:04 +0200 Subject: [PATCH 27/56] Adds abbriavted words to new-mnemonics --- staking_deposit/cli/new_mnemonic.py | 4 +- staking_deposit/intl/en/cli/new_mnemonic.json | 2 +- tests/test_cli/test_new_mnemonic.py | 84 ++++++++++++++++++- 3 files changed, 83 insertions(+), 7 deletions(-) diff --git a/staking_deposit/cli/new_mnemonic.py b/staking_deposit/cli/new_mnemonic.py index da2e7134..f288aeac 100644 --- a/staking_deposit/cli/new_mnemonic.py +++ b/staking_deposit/cli/new_mnemonic.py @@ -5,6 +5,7 @@ from staking_deposit.key_handling.key_derivation.mnemonic import ( get_mnemonic, + reconstruct_mnemonic, ) from staking_deposit.utils.click import ( captive_prompt_callback, @@ -47,7 +48,7 @@ def new_mnemonic(ctx: click.Context, mnemonic_language: str, **kwargs: Any) -> None: mnemonic = get_mnemonic(language=mnemonic_language, words_path=WORD_LISTS_PATH) test_mnemonic = '' - while mnemonic != test_mnemonic: + while mnemonic != reconstruct_mnemonic(test_mnemonic, WORD_LISTS_PATH): click.clear() click.echo(load_text(['msg_mnemonic_presentation'])) click.echo('\n\n%s\n\n' % mnemonic) @@ -55,7 +56,6 @@ def new_mnemonic(ctx: click.Context, mnemonic_language: str, **kwargs: Any) -> N click.clear() test_mnemonic = click.prompt(load_text(['msg_mnemonic_retype_prompt']) + '\n\n') - test_mnemonic = test_mnemonic.lower() click.clear() # Do NOT use mnemonic_password. ctx.obj = {'mnemonic': mnemonic, 'mnemonic_password': ''} diff --git a/staking_deposit/intl/en/cli/new_mnemonic.json b/staking_deposit/intl/en/cli/new_mnemonic.json index 4e6042c5..feee3ac2 100644 --- a/staking_deposit/intl/en/cli/new_mnemonic.json +++ b/staking_deposit/intl/en/cli/new_mnemonic.json @@ -10,6 +10,6 @@ }, "msg_mnemonic_presentation": "This is your mnemonic (seed phrase). Write it down and store it safely. It is the ONLY way to retrieve your deposit.", "msg_press_any_key": "Press any key when you have written down your mnemonic.", - "msg_mnemonic_retype_prompt": "Please type your mnemonic (separated by spaces) to confirm you have written it down." + "msg_mnemonic_retype_prompt": "Please type your mnemonic (separated by spaces) to confirm you have written it down. Note: you only need to enter the first 4 letters of each word if you'd prefer." } } diff --git a/tests/test_cli/test_new_mnemonic.py b/tests/test_cli/test_new_mnemonic.py index 098bc6a8..fb70a255 100644 --- a/tests/test_cli/test_new_mnemonic.py +++ b/tests/test_cli/test_new_mnemonic.py @@ -9,6 +9,7 @@ from staking_deposit.cli import new_mnemonic from staking_deposit.deposit import cli +from staking_deposit.key_handling.key_derivation.mnemonic import abbreviate_words from staking_deposit.utils.constants import DEFAULT_VALIDATOR_KEYS_FOLDER_NAME, ETH1_ADDRESS_WITHDRAWAL_PREFIX from staking_deposit.utils.intl import load_text from .helpers import clean_key_folder, get_permissions, get_uuid @@ -17,7 +18,7 @@ def test_new_mnemonic_bls_withdrawal(monkeypatch) -> None: # monkeypatch get_mnemonic def mock_get_mnemonic(language, words_path, entropy=None) -> str: - return "fakephrase" + return "abandon abandon abandon abandon abandon abandon abandon abandon abandon abandon abandon about" monkeypatch.setattr(new_mnemonic, "get_mnemonic", mock_get_mnemonic) @@ -28,7 +29,8 @@ def mock_get_mnemonic(language, words_path, entropy=None) -> str: os.mkdir(my_folder_path) runner = CliRunner() - inputs = ['english', 'english', '1', 'mainnet', 'MyPassword', 'MyPassword', 'fakephrase'] + inputs = ['english', 'english', '1', 'mainnet', 'MyPassword', 'MyPassword', + 'abandon abandon abandon abandon abandon abandon abandon abandon abandon abandon abandon about'] data = '\n'.join(inputs) result = runner.invoke(cli, ['new-mnemonic', '--folder', my_folder_path], input=data) assert result.exit_code == 0 @@ -56,7 +58,7 @@ def mock_get_mnemonic(language, words_path, entropy=None) -> str: def test_new_mnemonic_eth1_address_withdrawal(monkeypatch) -> None: # monkeypatch get_mnemonic def mock_get_mnemonic(language, words_path, entropy=None) -> str: - return "fakephrase" + return "abandon abandon abandon abandon abandon abandon abandon abandon abandon abandon abandon about" monkeypatch.setattr(new_mnemonic, "get_mnemonic", mock_get_mnemonic) @@ -67,7 +69,8 @@ def mock_get_mnemonic(language, words_path, entropy=None) -> str: os.mkdir(my_folder_path) runner = CliRunner() - inputs = ['english', '1', 'mainnet', 'MyPassword', 'MyPassword', 'fakephrase'] + inputs = ['english', '1', 'mainnet', 'MyPassword', 'MyPassword', + 'abandon abandon abandon abandon abandon abandon abandon abandon abandon abandon abandon about'] data = '\n'.join(inputs) eth1_withdrawal_address = '0x00000000219ab540356cbb839cbe05303d7705fa' arguments = [ @@ -178,3 +181,76 @@ async def test_script() -> None: # Clean up clean_key_folder(my_folder_path) + + +@pytest.mark.asyncio +async def test_script_abbreviated_mnemonic() -> None: + my_folder_path = os.path.join(os.getcwd(), 'TESTING_TEMP_FOLDER') + if not os.path.exists(my_folder_path): + os.mkdir(my_folder_path) + + if os.name == 'nt': # Windows + run_script_cmd = 'sh deposit.sh' + else: # Mac or Linux + run_script_cmd = './deposit.sh' + + install_cmd = run_script_cmd + ' install' + proc = await asyncio.create_subprocess_shell( + install_cmd, + ) + await proc.wait() + + cmd_args = [ + run_script_cmd, + '--language', 'english', + '--non_interactive', + 'new-mnemonic', + '--num_validators', '5', + '--mnemonic_language', 'english', + '--chain', 'mainnet', + '--keystore_password', 'MyPassword', + '--folder', my_folder_path, + ] + proc = await asyncio.create_subprocess_shell( + ' '.join(cmd_args), + stdin=asyncio.subprocess.PIPE, + stdout=asyncio.subprocess.PIPE, + ) + + seed_phrase = '' + parsing = False + mnemonic_json_file = os.path.join(os.getcwd(), 'staking_deposit/../staking_deposit/cli/', 'new_mnemonic.json') + async for out in proc.stdout: + output = out.decode('utf-8').rstrip() + if output.startswith(load_text(['msg_mnemonic_presentation'], mnemonic_json_file, 'new_mnemonic')): + parsing = True + elif output.startswith(load_text(['msg_mnemonic_retype_prompt'], mnemonic_json_file, 'new_mnemonic')): + parsing = False + elif parsing: + seed_phrase += output + if len(seed_phrase) > 0: + abbreviated_mnemonic = ' '.join(abbreviate_words(seed_phrase.split(' '))) + encoded_phrase = abbreviated_mnemonic.encode() + proc.stdin.write(encoded_phrase) + proc.stdin.write(b'\n') + + assert len(seed_phrase) > 0 + + # Check files + validator_keys_folder_path = os.path.join(my_folder_path, DEFAULT_VALIDATOR_KEYS_FOLDER_NAME) + _, _, key_files = next(os.walk(validator_keys_folder_path)) + + all_uuid = [ + get_uuid(validator_keys_folder_path + '/' + key_file) + for key_file in key_files + if key_file.startswith('keystore') + ] + assert len(set(all_uuid)) == 5 + + # Verify file permissions + if os.name == 'posix': + for file_name in key_files: + assert get_permissions(validator_keys_folder_path, file_name) == '0o440' + + # Clean up + clean_key_folder(my_folder_path) From 0d3440e7ba2081530155967ea4a8dfe772c7dc10 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 28 Mar 2022 11:24:52 +0200 Subject: [PATCH 28/56] Adds check that multiple mnemonic languages aren't detected --- .../key_handling/key_derivation/mnemonic.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/staking_deposit/key_handling/key_derivation/mnemonic.py b/staking_deposit/key_handling/key_derivation/mnemonic.py index 49f5ada1..378bafdf 100644 --- a/staking_deposit/key_handling/key_derivation/mnemonic.py +++ b/staking_deposit/key_handling/key_derivation/mnemonic.py @@ -108,6 +108,7 @@ def reconstruct_mnemonic(mnemonic: str, words_path: str) -> Optional[str]: languages = determine_mnemonic_language(mnemonic, words_path) except ValueError: return None + reconstructed_mnemonic = None for language in languages: try: word_list = abbreviate_words(_get_word_list(language, words_path)) @@ -122,12 +123,17 @@ def reconstruct_mnemonic(mnemonic: str, words_path: str) -> Optional[str]: entropy_bits = entropy.to_bytes(checksum_length * 4, 'big') full_word_list = _get_word_list(language, words_path) if _get_checksum(entropy_bits) == checksum: - return ' '.join([_index_to_word(full_word_list, index) for index in word_indices]) + """ + This check guarantees that only one language has a valid mnemonic. + It is needed to ensure abbrivated words aren't valid in multiple languages + """ + assert reconstructed_mnemonic is None + reconstructed_mnemonic = ' '.join([_index_to_word(full_word_list, index) for index in word_indices]) else: pass except ValueError: pass - return None + return reconstructed_mnemonic def get_mnemonic(*, language: str, words_path: str, entropy: Optional[bytes]=None) -> str: From 5e343d4cf5d9b7dfa0eca30c3f0f922a6a4fe332 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Mon, 28 Mar 2022 15:10:46 +0200 Subject: [PATCH 29/56] version bump -> v2.1 --- README.md | 6 +++--- setup.py | 2 +- staking_deposit/settings.py | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 54338b1d..d5264b58 100644 --- a/README.md +++ b/README.md @@ -68,7 +68,7 @@ ## Introduction -`deposit-cli` is a tool for creating [EIP-2335 format](https://eips.ethereum.org/EIPS/eip-2335) BLS12-381 keystores and a corresponding `deposit_data*.json` file for [Ethereum 2.0 Launchpad](https://github.com/ethereum/staking-launchpad). +`deposit-cli` is a tool for creating [EIP-2335 format](https://eips.ethereum.org/EIPS/eip-2335) BLS12-381 keystores and a corresponding `deposit_data*.json` file for [Ethereum Staking Launchpad](https://github.com/ethereum/staking-launchpad). - **Warning: Please generate your keystores on your own safe, completely offline device.** - **Warning: Please backup your mnemonic, keystores, and password securely.** @@ -94,7 +94,7 @@ On Unix-based systems, keystores and the `deposit_data*.json` have `440`/`-r--r- ##### Step 1. Installation -See [releases page](https://github.com/ethereum/eth2.0-deposit-cli/releases) to download and decompress the corresponding binary files. +See [releases page](https://github.com/ethereum/staking-deposit-cli/releases) to download and decompress the corresponding binary files. ##### Step 2. Create keys and `deposit_data-*.json` @@ -338,7 +338,7 @@ See [here](#successful-message) ##### Step 1. Installation -See [releases page](https://github.com/ethereum/eth2.0-deposit-cli/releases) to download and decompress the corresponding binary files. +See [releases page](https://github.com/ethereum/staking-deposit-cli/releases) to download and decompress the corresponding binary files. ##### Step 2. Create keys and `deposit_data-*.json` diff --git a/setup.py b/setup.py index d14ea157..bb48f27b 100644 --- a/setup.py +++ b/setup.py @@ -6,7 +6,7 @@ setup( name="staking_deposit", - version='2.0.0', + version='2.1.0', py_modules=["staking_deposit"], packages=find_packages(exclude=('tests', 'docs')), python_requires=">=3.8,<4", diff --git a/staking_deposit/settings.py b/staking_deposit/settings.py index abf5c973..dbaced5f 100644 --- a/staking_deposit/settings.py +++ b/staking_deposit/settings.py @@ -1,7 +1,7 @@ from typing import Dict, NamedTuple -DEPOSIT_CLI_VERSION = '2.0.0' +DEPOSIT_CLI_VERSION = '2.1.0' class BaseChainSetting(NamedTuple): From 9edea6351e5e35aca6f42fe7c9b02e72d4231a3a Mon Sep 17 00:00:00 2001 From: Hsiao-Wei Wang Date: Tue, 29 Mar 2022 15:48:08 +0800 Subject: [PATCH 30/56] Kick venv cache version --- .circleci/config.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index bf143bac..48adba30 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -30,12 +30,12 @@ jobs: steps: - checkout - restore_cache: - key: venv-deps2-{{ arch }}-{{ .Branch }}-{{ checksum "requirements.txt" }}-{{ checksum "requirements_test.txt" }}-{{ checksum "setup.py" }}-{{ checksum "Makefile" }} + key: venv-deps2-{{ arch }}-{{ .Branch }}-{{ checksum "requirements.txt" }}-{{ checksum "requirements_test.txt" }}-{{ checksum "setup.py" }}-{{ checksum "Makefile" }}-v2 - run: name: Install requirements in venv command: make venv_build_test - save_cache: - key: venv-deps2-{{ arch }}-{{ .Branch }}-{{ checksum "requirements.txt" }}-{{ checksum "requirements_test.txt" }}-{{ checksum "setup.py" }}-{{ checksum "Makefile" }} + key: venv-deps2-{{ arch }}-{{ .Branch }}-{{ checksum "requirements.txt" }}-{{ checksum "requirements_test.txt" }}-{{ checksum "setup.py" }}-{{ checksum "Makefile" }}-v2 paths: - ./venv venv_pytest: @@ -45,7 +45,7 @@ jobs: steps: - checkout - restore_cache: - key: venv-deps2-{{ arch }}-{{ .Branch }}-{{ checksum "requirements.txt" }}-{{ checksum "requirements_test.txt" }}-{{ checksum "setup.py" }}-{{ checksum "Makefile" }} + key: venv-deps2-{{ arch }}-{{ .Branch }}-{{ checksum "requirements.txt" }}-{{ checksum "requirements_test.txt" }}-{{ checksum "setup.py" }}-{{ checksum "Makefile" }}-v2 - run: name: Run tests with venv command: make venv_test @@ -61,7 +61,7 @@ jobs: steps: - checkout - restore_cache: - key: venv-deps2-{{ arch }}-{{ .Branch }}-{{ checksum "requirements.txt" }}-{{ checksum "requirements_test.txt" }}-{{ checksum "setup.py" }}-{{ checksum "Makefile" }} + key: venv-deps2-{{ arch }}-{{ .Branch }}-{{ checksum "requirements.txt" }}-{{ checksum "requirements_test.txt" }}-{{ checksum "setup.py" }}-{{ checksum "Makefile" }}-v2 - run: name: Run linter with venv command: make venv_lint From 3be3723a243b8aed20b13c2303dc87c4a61f3244 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Tue, 29 Mar 2022 15:03:24 +0200 Subject: [PATCH 31/56] Actually shortens words for abbrviated mnemonic test vectors --- tests/test_key_handling/test_key_derivation/test_mnemonic.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/test_key_handling/test_key_derivation/test_mnemonic.py b/tests/test_key_handling/test_key_derivation/test_mnemonic.py index 03aaf8b0..9d1ae9d0 100644 --- a/tests/test_key_handling/test_key_derivation/test_mnemonic.py +++ b/tests/test_key_handling/test_key_derivation/test_mnemonic.py @@ -4,7 +4,6 @@ from typing import ( Sequence, ) -from unicodedata import normalize from staking_deposit.utils.constants import ( MNEMONIC_LANG_OPTIONS, @@ -12,6 +11,7 @@ from staking_deposit.key_handling.key_derivation.mnemonic import ( _index_to_word, _get_word_list, + abbreviate_words, get_seed, get_mnemonic, reconstruct_mnemonic, @@ -52,7 +52,8 @@ def test_reconstruct_mnemonic(test_mnemonic: str) -> None: def abbreviate_mnemonic(mnemonic: str) -> str: words = str.split(mnemonic) - words = [normalize('NFKC', word) for word in words] + words = abbreviate_words(words) + assert all([len(word) <= 4 for word in words]) return str.join(' ', words) From e35ed2c3a58a2a4069e4ae28f0509c067138cfc8 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Tue, 29 Mar 2022 16:58:36 +0200 Subject: [PATCH 32/56] Re-implement Clarifies when abbreviated words are used --- .../key_handling/key_derivation/mnemonic.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/staking_deposit/key_handling/key_derivation/mnemonic.py b/staking_deposit/key_handling/key_derivation/mnemonic.py index 378bafdf..d1d98b4a 100644 --- a/staking_deposit/key_handling/key_derivation/mnemonic.py +++ b/staking_deposit/key_handling/key_derivation/mnemonic.py @@ -111,13 +111,13 @@ def reconstruct_mnemonic(mnemonic: str, words_path: str) -> Optional[str]: reconstructed_mnemonic = None for language in languages: try: - word_list = abbreviate_words(_get_word_list(language, words_path)) - mnemonic_list = abbreviate_words(mnemonic.lower().split(' ')) - if len(mnemonic_list) not in range(12, 25, 3): + abbrev_word_list = abbreviate_words(_get_word_list(language, words_path)) + abbrev_mnemonic_list = abbreviate_words(mnemonic.lower().split(' ')) + if len(abbrev_mnemonic_list) not in range(12, 25, 3): return None - word_indices = [_word_to_index(word_list, word) for word in mnemonic_list] + word_indices = [_word_to_index(abbrev_word_list, word) for word in abbrev_mnemonic_list] mnemonic_int = _uint11_array_to_uint(word_indices) - checksum_length = len(mnemonic_list) // 3 + checksum_length = len(abbrev_mnemonic_list) // 3 checksum = mnemonic_int & 2**checksum_length - 1 entropy = (mnemonic_int - checksum) >> checksum_length entropy_bits = entropy.to_bytes(checksum_length * 4, 'big') From 1c5bf42bdf933b6ecce2653fbaab6fd3ab2a6a13 Mon Sep 17 00:00:00 2001 From: Hsiao-Wei Wang Date: Tue, 17 May 2022 17:30:21 +0200 Subject: [PATCH 33/56] Add Ropsten config --- staking_deposit/settings.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/staking_deposit/settings.py b/staking_deposit/settings.py index dbaced5f..868cf281 100644 --- a/staking_deposit/settings.py +++ b/staking_deposit/settings.py @@ -13,10 +13,13 @@ class BaseChainSetting(NamedTuple): PRATER = 'prater' KINTSUGI = 'kintsugi' KILN = 'kiln' +ROPSTEN = 'ropsten' # Mainnet setting MainnetSetting = BaseChainSetting(NETWORK_NAME=MAINNET, GENESIS_FORK_VERSION=bytes.fromhex('00000000')) +# Ropsten setting +RopstenSetting = BaseChainSetting(NETWORK_NAME=ROPSTEN, GENESIS_FORK_VERSION=bytes.fromhex('80000069')) # Testnet (spec v1.0.1) PraterSetting = BaseChainSetting(NETWORK_NAME=PRATER, GENESIS_FORK_VERSION=bytes.fromhex('00001020')) # Merge Testnet (spec v1.1.4) @@ -30,6 +33,7 @@ class BaseChainSetting(NamedTuple): PRATER: PraterSetting, KINTSUGI: KintsugiSetting, KILN: KilnSetting, + ROPSTEN: RopstenSetting, } From b2993c0a58328bbd5719c53e829b709b2ac3d4e6 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Tue, 24 May 2022 13:23:43 +0200 Subject: [PATCH 34/56] Bumps version number to v2.2.0 --- setup.py | 2 +- staking_deposit/settings.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/setup.py b/setup.py index bb48f27b..3e368d44 100644 --- a/setup.py +++ b/setup.py @@ -6,7 +6,7 @@ setup( name="staking_deposit", - version='2.1.0', + version='2.2.0', py_modules=["staking_deposit"], packages=find_packages(exclude=('tests', 'docs')), python_requires=">=3.8,<4", diff --git a/staking_deposit/settings.py b/staking_deposit/settings.py index 868cf281..61de6a08 100644 --- a/staking_deposit/settings.py +++ b/staking_deposit/settings.py @@ -1,7 +1,7 @@ from typing import Dict, NamedTuple -DEPOSIT_CLI_VERSION = '2.1.0' +DEPOSIT_CLI_VERSION = '2.2.0' class BaseChainSetting(NamedTuple): From 708771848e1c6195968dad09ec216d84bb3b3f1c Mon Sep 17 00:00:00 2001 From: Hsiao-Wei Wang Date: Fri, 10 Jun 2022 22:55:15 +0800 Subject: [PATCH 35/56] Add Sepolia support and remove Kintsugi support --- staking_deposit/settings.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/staking_deposit/settings.py b/staking_deposit/settings.py index 61de6a08..b3e43d36 100644 --- a/staking_deposit/settings.py +++ b/staking_deposit/settings.py @@ -11,19 +11,19 @@ class BaseChainSetting(NamedTuple): MAINNET = 'mainnet' PRATER = 'prater' -KINTSUGI = 'kintsugi' KILN = 'kiln' ROPSTEN = 'ropsten' +SEPOLIA = 'sepolia' # Mainnet setting MainnetSetting = BaseChainSetting(NETWORK_NAME=MAINNET, GENESIS_FORK_VERSION=bytes.fromhex('00000000')) # Ropsten setting RopstenSetting = BaseChainSetting(NETWORK_NAME=ROPSTEN, GENESIS_FORK_VERSION=bytes.fromhex('80000069')) +# Sepolia setting +SepoliaSetting = BaseChainSetting(NETWORK_NAME=SEPOLIA, GENESIS_FORK_VERSION=bytes.fromhex('90000069')) # Testnet (spec v1.0.1) PraterSetting = BaseChainSetting(NETWORK_NAME=PRATER, GENESIS_FORK_VERSION=bytes.fromhex('00001020')) -# Merge Testnet (spec v1.1.4) -KintsugiSetting = BaseChainSetting(NETWORK_NAME=KINTSUGI, GENESIS_FORK_VERSION=bytes.fromhex('60000069')) # Merge Testnet (spec v1.1.9) KilnSetting = BaseChainSetting(NETWORK_NAME=KILN, GENESIS_FORK_VERSION=bytes.fromhex('70000069')) @@ -31,9 +31,9 @@ class BaseChainSetting(NamedTuple): ALL_CHAINS: Dict[str, BaseChainSetting] = { MAINNET: MainnetSetting, PRATER: PraterSetting, - KINTSUGI: KintsugiSetting, KILN: KilnSetting, ROPSTEN: RopstenSetting, + SEPOLIA: SepoliaSetting, } From cad017c9c7952ea95cc03e2bc73db2dac67ca484 Mon Sep 17 00:00:00 2001 From: lightclient <14004106+lightclient@users.noreply.github.com> Date: Sat, 18 Jun 2022 14:33:39 +0200 Subject: [PATCH 36/56] replace backslashes with forwardslashes --- README.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index d5264b58..b253147c 100644 --- a/README.md +++ b/README.md @@ -456,7 +456,7 @@ For the [virtualenv](https://virtualenv.pypa.io/en/latest/) users, you can creat ```cmd pip3 install virtualenv virtualenv venv -.\venv\Scripts\activate +./venv/Scripts/activate ``` and install the dependencies: @@ -471,23 +471,23 @@ pip3 install -r requirements.txt Run one of the following command to enter the interactive CLI: ```cmd -python .\staking_deposit\deposit.py new-mnemonic +python ./staking_deposit/deposit.py new-mnemonic ``` or ```cmd -python .\staking_deposit\deposit.py existing-mnemonic +python ./staking_deposit/deposit.py existing-mnemonic ``` You can also run the tool with optional arguments: ```cmd -python .\staking_deposit\deposit.py new-mnemonic --num_validators= --mnemonic_language=english --chain= --folder= +python ./staking_deposit/deposit.py new-mnemonic --num_validators= --mnemonic_language=english --chain= --folder= ``` ```cmd -python .\staking_deposit\deposit.pyexisting-mnemonic --num_validators= --validator_start_index= --chain= --folder= +python ./staking_deposit/deposit.pyexisting-mnemonic --num_validators= --validator_start_index= --chain= --folder= ``` ###### Language Argument From 160d69b52b4f20891ffee91c51a346937e8eb78c Mon Sep 17 00:00:00 2001 From: Hsiao-Wei Wang Date: Thu, 28 Jul 2022 18:06:54 +0800 Subject: [PATCH 37/56] Update chain settings 1. Add Goerli, which is an alias of Prater 2. Remove Kintsugi --- staking_deposit/settings.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/staking_deposit/settings.py b/staking_deposit/settings.py index 61de6a08..61045d3e 100644 --- a/staking_deposit/settings.py +++ b/staking_deposit/settings.py @@ -10,30 +10,30 @@ class BaseChainSetting(NamedTuple): MAINNET = 'mainnet' +ROPSTEN = 'ropsten' +GOERLI = 'goerli' PRATER = 'prater' -KINTSUGI = 'kintsugi' KILN = 'kiln' -ROPSTEN = 'ropsten' # Mainnet setting MainnetSetting = BaseChainSetting(NETWORK_NAME=MAINNET, GENESIS_FORK_VERSION=bytes.fromhex('00000000')) # Ropsten setting RopstenSetting = BaseChainSetting(NETWORK_NAME=ROPSTEN, GENESIS_FORK_VERSION=bytes.fromhex('80000069')) -# Testnet (spec v1.0.1) -PraterSetting = BaseChainSetting(NETWORK_NAME=PRATER, GENESIS_FORK_VERSION=bytes.fromhex('00001020')) -# Merge Testnet (spec v1.1.4) -KintsugiSetting = BaseChainSetting(NETWORK_NAME=KINTSUGI, GENESIS_FORK_VERSION=bytes.fromhex('60000069')) +# GOERLI (PRATER is alias) +_GOERLI_GENESIS_FORK_VERSION = bytes.fromhex('00001020') +GoerliSetting = BaseChainSetting(NETWORK_NAME=GOERLI, GENESIS_FORK_VERSION=_GOERLI_GENESIS_FORK_VERSION) +PraterSetting = BaseChainSetting(NETWORK_NAME=PRATER, GENESIS_FORK_VERSION=_GOERLI_GENESIS_FORK_VERSION) # Merge Testnet (spec v1.1.9) KilnSetting = BaseChainSetting(NETWORK_NAME=KILN, GENESIS_FORK_VERSION=bytes.fromhex('70000069')) ALL_CHAINS: Dict[str, BaseChainSetting] = { MAINNET: MainnetSetting, + ROPSTEN: RopstenSetting, + GOERLI: GoerliSetting, PRATER: PraterSetting, - KINTSUGI: KintsugiSetting, KILN: KilnSetting, - ROPSTEN: RopstenSetting, } From a57373be16f90c37b39b34ff3b155dce23614b59 Mon Sep 17 00:00:00 2001 From: Hsiao-Wei Wang Date: Thu, 28 Jul 2022 18:09:48 +0800 Subject: [PATCH 38/56] Use Goerli as the "main name". Do not show Prater in prompt message --- staking_deposit/cli/generate_keys.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/staking_deposit/cli/generate_keys.py b/staking_deposit/cli/generate_keys.py index 5d8aa582..4caa3b7b 100644 --- a/staking_deposit/cli/generate_keys.py +++ b/staking_deposit/cli/generate_keys.py @@ -34,6 +34,7 @@ from staking_deposit.settings import ( ALL_CHAINS, MAINNET, + PRATER, get_chain_setting, ) @@ -87,7 +88,8 @@ def generate_keys_arguments_decorator(function: Callable[..., Any]) -> Callable[ param_decls='--chain', prompt=choice_prompt_func( lambda: load_text(['chain', 'prompt'], func='generate_keys_arguments_decorator'), - list(ALL_CHAINS.keys()) + # Since `prater` is alias of `goerli`, do not show `prater` in the prompt message. + list(key for key in ALL_CHAINS.keys() if key != PRATER) ), ), jit_option( From 88166baa72f98bb62ae757c9cbbb43c57c83b949 Mon Sep 17 00:00:00 2001 From: Anthony Burzillo Date: Thu, 14 Jul 2022 12:16:22 -0400 Subject: [PATCH 39/56] [README] Add GitPOAP Badge to Display Number of Minted GitPOAPs for Contributors --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index d5264b58..eec5bd7b 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # staking-deposit-cli +[![GitPOAP Badge](https://public-api.gitpoap.io/v1/repo/ethereum/staking-deposit-cli/badge)](https://www.gitpoap.io/gh/ethereum/staking-deposit-cli) + From 6d69439034903053d8dc26253dab411ec1a978d7 Mon Sep 17 00:00:00 2001 From: Hsiao-Wei Wang Date: Sat, 30 Jul 2022 14:02:38 +0800 Subject: [PATCH 40/56] PR feedback from @CarlBeek --- staking_deposit/settings.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/staking_deposit/settings.py b/staking_deposit/settings.py index 61045d3e..491ca4e6 100644 --- a/staking_deposit/settings.py +++ b/staking_deposit/settings.py @@ -20,10 +20,8 @@ class BaseChainSetting(NamedTuple): MainnetSetting = BaseChainSetting(NETWORK_NAME=MAINNET, GENESIS_FORK_VERSION=bytes.fromhex('00000000')) # Ropsten setting RopstenSetting = BaseChainSetting(NETWORK_NAME=ROPSTEN, GENESIS_FORK_VERSION=bytes.fromhex('80000069')) -# GOERLI (PRATER is alias) -_GOERLI_GENESIS_FORK_VERSION = bytes.fromhex('00001020') -GoerliSetting = BaseChainSetting(NETWORK_NAME=GOERLI, GENESIS_FORK_VERSION=_GOERLI_GENESIS_FORK_VERSION) -PraterSetting = BaseChainSetting(NETWORK_NAME=PRATER, GENESIS_FORK_VERSION=_GOERLI_GENESIS_FORK_VERSION) +# Goreli setting +GoerliSetting = BaseChainSetting(NETWORK_NAME=GOERLI, GENESIS_FORK_VERSION=bytes.fromhex('00001020')) # Merge Testnet (spec v1.1.9) KilnSetting = BaseChainSetting(NETWORK_NAME=KILN, GENESIS_FORK_VERSION=bytes.fromhex('70000069')) @@ -32,7 +30,7 @@ class BaseChainSetting(NamedTuple): MAINNET: MainnetSetting, ROPSTEN: RopstenSetting, GOERLI: GoerliSetting, - PRATER: PraterSetting, + PRATER: GoerliSetting, # Prater is the old name of the Prater/Goerli testnet KILN: KilnSetting, } From 7484a032fd47fd442e6a44f0858ba7dff4601637 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Sun, 31 Jul 2022 15:14:24 +0200 Subject: [PATCH 41/56] Bump CI Xcode version to 13.4.1 to avoid CI image depreication --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 48adba30..85ce3e15 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -245,7 +245,7 @@ jobs: path: /tmp/artifacts build-macos: macos: - xcode: 12.4.0 + xcode: 13.4.1 working_directory: ~/repo steps: - run: xcodebuild -version From c078fad3f2a02ff9e66a6a0da23b5c26cbb85773 Mon Sep 17 00:00:00 2001 From: Carl Beekhuizen Date: Sun, 31 Jul 2022 15:33:21 +0200 Subject: [PATCH 42/56] Version bump -> 2.3.0 --- setup.py | 2 +- staking_deposit/settings.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/setup.py b/setup.py index 3e368d44..f9ab2ac6 100644 --- a/setup.py +++ b/setup.py @@ -6,7 +6,7 @@ setup( name="staking_deposit", - version='2.2.0', + version='2.3.0', py_modules=["staking_deposit"], packages=find_packages(exclude=('tests', 'docs')), python_requires=">=3.8,<4", diff --git a/staking_deposit/settings.py b/staking_deposit/settings.py index 491ca4e6..a38fb836 100644 --- a/staking_deposit/settings.py +++ b/staking_deposit/settings.py @@ -1,7 +1,7 @@ from typing import Dict, NamedTuple -DEPOSIT_CLI_VERSION = '2.2.0' +DEPOSIT_CLI_VERSION = '2.3.0' class BaseChainSetting(NamedTuple): From 5f9d2744d9941e9776f4c7227d064c97260c613a Mon Sep 17 00:00:00 2001 From: jeremie-H Date: Sun, 24 Jul 2022 20:46:40 +0200 Subject: [PATCH 43/56] =?UTF-8?q?=F0=9F=8C=90=20fix=20fr=20translation=20f?= =?UTF-8?q?or=20starting=20index?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- staking_deposit/intl/fr/cli/existing_mnemonic.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/staking_deposit/intl/fr/cli/existing_mnemonic.json b/staking_deposit/intl/fr/cli/existing_mnemonic.json index 0375f61d..f7f68ab4 100644 --- a/staking_deposit/intl/fr/cli/existing_mnemonic.json +++ b/staking_deposit/intl/fr/cli/existing_mnemonic.json @@ -17,7 +17,7 @@ "arg_validator_start_index": { "help": "Saisissez l'index (numéro de clé) à partir duquel vous souhaitez commencer à générer d'autres clés. Par exemple, si vous avez généré 4 clés dans le passé, entrez 4.", "prompt": "Saisissez l'index (numéro de clé) à partir duquel vous souhaitez commencer à générer d'autres clés. Par exemple, si vous avez généré 4 clés dans le passé, entrez 4.", - "confirm": "Veuillez confirmer le mot de passe." + "confirm": "Veuillez confirmer l'index." } } } From b9b4a1c03cea95c398ba53b4ee929478cfad4899 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Muhammed=20Kadir=20Y=C3=BCcel?= Date: Tue, 21 Jun 2022 10:36:22 +0300 Subject: [PATCH 44/56] Add Turkish translation for the interface --- .../intl/tr/cli/existing_mnemonic.json | 25 +++++++++++++ .../intl/tr/cli/generate_keys.json | 35 +++++++++++++++++++ staking_deposit/intl/tr/cli/new_mnemonic.json | 15 ++++++++ staking_deposit/intl/tr/credentials.json | 14 ++++++++ staking_deposit/intl/tr/deposit.json | 5 +++ staking_deposit/intl/tr/utils/validation.json | 14 ++++++++ staking_deposit/utils/constants.py | 1 + 7 files changed, 109 insertions(+) create mode 100644 staking_deposit/intl/tr/cli/existing_mnemonic.json create mode 100644 staking_deposit/intl/tr/cli/generate_keys.json create mode 100644 staking_deposit/intl/tr/cli/new_mnemonic.json create mode 100644 staking_deposit/intl/tr/credentials.json create mode 100644 staking_deposit/intl/tr/deposit.json create mode 100644 staking_deposit/intl/tr/utils/validation.json diff --git a/staking_deposit/intl/tr/cli/existing_mnemonic.json b/staking_deposit/intl/tr/cli/existing_mnemonic.json new file mode 100644 index 00000000..17066ccc --- /dev/null +++ b/staking_deposit/intl/tr/cli/existing_mnemonic.json @@ -0,0 +1,25 @@ +{ + "validate_mnemonic": { + "err_invalid_mnemonic": "İpucu kelimeleri doğru değil, lütfen yazım hatalarını kontrol edin." + }, + "existing_mnemonic": { + "arg_existing_mnemonic": { + "help": "Mevcut ipucu kelimelerinden anahtar oluşturun (veya kurtarın)" + }, + "arg_mnemonic": { + "help": "Anahtarlarınız oluştururken kullandığınız ipucu kelimeleri. (Bu parametreyi kullanmamanız ve size sorulduğunda ipucu kelimelerini girmeniz tavsiye edilir, aksi taktirde ipucu kelimeleriniz komut satırı geçmişinde gözükecektir.)", + "prompt": "İpucu kelimelerinizin arasında boşluk bırakarak giriniz (\" \"). Not: her kelimenin ilk 4 harfini girmeniz yeterli olacaktır." + }, + "arg_mnemonic_password": { + "help": "Büyük ihtimalle aradığınız parametre bu değil: bu parametre ipucu kelimeleri için şifredir, anahtar deposu şifresi değildir. Daha önce şifre vermediyseniz burada şifre girmeniz anahtarlarınızın (yani varlıklarınızın) kaybolmasına neden olabilir! Eğer ipucu kelimelerinizi bu aracı kullanarak oluşturduysanız, şifre vermemişsiniz demektir. Fakat ipucu kelimelerinizin güvenliğini \"arttırmak\" için şifre verdiğinize eminseniz, şifrenizi buraya girmelisiniz.", + "prompt": "İpucu kelime şifrenizi giriniz (daha önce sağladıysanız). Unutmayacağınıza emin olun, bu şifre kurtarılamaz.", + "confirm": "Onaylamak için ipucu kelime şifrenizi tekrar giriniz. Daha önce şifre vermediyseniz burada şifre girmeniz anahtarlarınızın (yani varlıklarınızın) kaybolmasına neden olabilir! Eğer ipucu kelimelerinizi bu aracı kullanarak oluşturduysanız, şifre vermemişsiniz demektir. Fakat ipucu kelimelerinizin güvenliğini \"arttırmak\" için şifre verdiğinize eminseniz, şifrenizi buraya girmelisiniz.", + "mismatch": "Girdiğiniz ipucu kelime şifresi eşleşmiyor, lütfen tekrar deneyiniz." + }, + "arg_validator_start_index": { + "help": "Daha fazla anahtar oluşturmaya başlamak istediğiniz sırayı (anahtar numarası) giriniz. Örneğin, daha önce 4 anahtar oluşturduysanız, buraya 4 girmeniz gerekir.", + "prompt": "Daha fazla anahtar oluşturmaya başlamak istediğiniz sırayı (anahtar numarası) giriniz. Örneğin, daha önce 4 anahtar oluşturduysanız, buraya 4 girmeniz gerekir.", + "confirm": "Lütfen onaylamak için sırayı tekrar girin" + } + } +} diff --git a/staking_deposit/intl/tr/cli/generate_keys.json b/staking_deposit/intl/tr/cli/generate_keys.json new file mode 100644 index 00000000..bcfc3bb5 --- /dev/null +++ b/staking_deposit/intl/tr/cli/generate_keys.json @@ -0,0 +1,35 @@ +{ + "validate_eth1_withdrawal_address": { + "err_invalid_ECDSA_hex_addr": "Girilen Eth1 adresi onaltılık sistemde kodlanmamıştır.", + "msg_ECDSA_addr_withdrawal": "**[Uyarı] bir Eth1 adresini varlık çekme adresi olarak giriyorsunuz. Lütfen bu adresin kontrolünün sizde olduğundan emin olun.**" + }, + "generate_keys_arguments_decorator": { + "num_validators": { + "help": "Oluşturmak istediğiniz yeni doğrulayıcı anahtarlarının sayısını giriniz (daha fazlasını daha sonra da oluşturabilirsiniz)", + "prompt": "Lütfen kaç tane doğrulayıcı çalıştırmak istediğinizi seçin" + }, + "folder": { + "help": "Anahtar depoları ve depozitolar için dizin yolu. Varsayılan olarak `./validator_keys` yolunu gösterir." + }, + "chain": { + "help": "Hedeflenen Ethereum PoS ağının ismi. Depozito olarak ETH kullanıyorsanız \"mainnet\" kullanın", + "prompt": "Lütfen (mainnet veya testnet) ağ/zincir adını seçin" + }, + "keystore_password": { + "help": "Anahtar depolarınızı koruyacak şifre. Ethereum onaylayıcılarınızı kurarken bu şifreyi tekrar girmeniz gerekecek. (Bu parametreyi kullanmamanız ve size sorulduğunda ipucu kelimelerini girmeniz tavsiye edilir, aksi taktirde şifreniz komut satırı geçmişinde gözükecektir.)", + "prompt": "Onaylayıcı anahtar depolarınızı koruyan bir şifre oluşturun. Ethereum onaylayıcılarınızı kurarken bu şifreyi tekrar girmeniz gerekecek.", + "confirm": "Anahtar deposu şifrenizi onaylamak için tekrar girin", + "mismatch": "Hata: girilen değerler eşleşmiyor. Tekrar deneyin." + }, + "eth1_withdrawal_address": { + "help": "Eğer bu alan girilmiş ve geçerliyse, verilen Eth1 adresi varlık çekme adresi olarak kullanılacaktır. Aksi taktirde, ipucu kelimelerinden üretilmiş bir genel anahtar kullanılır." + } + }, + "generate_keys": { + "msg_key_creation": "Anahtarlarınız oluşturuluyor.", + "msg_creation_success": "\nBaşarılı!\nAnahtarlarınızı burada bulabilirsiniz: ", + "msg_pause": "\n\nHerhangi bir tuşa basın.", + "err_verify_keystores": "Anahtar depoları doğrulanamadı.", + "err_verify_deposit": "Depozito JSON dosyaları doğrulanamadı." + } +} diff --git a/staking_deposit/intl/tr/cli/new_mnemonic.json b/staking_deposit/intl/tr/cli/new_mnemonic.json new file mode 100644 index 00000000..cbed0575 --- /dev/null +++ b/staking_deposit/intl/tr/cli/new_mnemonic.json @@ -0,0 +1,15 @@ +{ + "new_mnemonic": { + "arg_new_mnemonic": { + "help": "Yeni ipucu kelimeler ve anahtarlar oluşturun" + }, + "arg_mnemonic_language": { + "default": "english", + "help": "İpucu kelimelerinizin dili", + "prompt": "Lütfen ipucu kelimelerinin dilini seçin" + }, + "msg_mnemonic_presentation": "Bunlar ipucu kelimelerinizdir (tohum ifadeleri). Bir yere not alın ve güvenli bir şekilde saklayın. Depozitoyu YALNIZCA bununla geri alabilirsiniz.", + "msg_press_any_key": "İpucu kelimelerinizi not aldığınızda bir tuşa basın.", + "msg_mnemonic_retype_prompt": "Lütfen ipucu kelimelerinizi not aldığınızı doğrulamak amacıyla (aralarında boşluk bırakarak) yazın. Not: kelimelerin yalnızca ilk 4 harfini yazmanız yeterlidir." + } +} diff --git a/staking_deposit/intl/tr/credentials.json b/staking_deposit/intl/tr/credentials.json new file mode 100644 index 00000000..cc5fd513 --- /dev/null +++ b/staking_deposit/intl/tr/credentials.json @@ -0,0 +1,14 @@ +{ + "from_mnemonic": { + "msg_key_creation": "Anahtarlarınız oluşturuluyor:\t\t" + }, + "export_keystores": { + "msg_keystore_creation": "Anahtar depolarınız oluşturuluyor:\t" + }, + "export_deposit_data_json": { + "msg_depositdata_creation": "Depozito veriniz (depositdata) oluşturuluyor:\t" + }, + "verify_keystores": { + "msg_keystore_verification": "Anahtar depolarınız doğrulanıyor:\t" + } +} diff --git a/staking_deposit/intl/tr/deposit.json b/staking_deposit/intl/tr/deposit.json new file mode 100644 index 00000000..b53983c9 --- /dev/null +++ b/staking_deposit/intl/tr/deposit.json @@ -0,0 +1,5 @@ +{ + "check_python_version": { + "err_python_version": "Python sürümünüz yetersiz, lütfen 3.8 sürümü veya daha yenisini yükleyin." + } +} diff --git a/staking_deposit/intl/tr/utils/validation.json b/staking_deposit/intl/tr/utils/validation.json new file mode 100644 index 00000000..73fcef98 --- /dev/null +++ b/staking_deposit/intl/tr/utils/validation.json @@ -0,0 +1,14 @@ +{ + "verify_deposit_data_json": { + "msg_deposit_verification": "Depozitonuz doğrulanıyor:\t" + }, + "validate_password_strength": { + "msg_password_length": "Şifre uzunluğu en az 8 olmalıdır. Lütfen tekrar girin." + }, + "validate_int_range": { + "err_not_positive_integer": "Pozitif tam sayı değil. Lütfen tekrar girin." + }, + "validate_choice": { + "err_invalid_choice": "Geçerli bir seçim değil. Lütfen seçiminizi tekrar girin." + } +} diff --git a/staking_deposit/utils/constants.py b/staking_deposit/utils/constants.py index 42015bb0..12f6122a 100644 --- a/staking_deposit/utils/constants.py +++ b/staking_deposit/utils/constants.py @@ -48,6 +48,7 @@ def _add_index_to_options(d: Dict[str, List[str]]) -> Dict[str, List[str]]: 'ko': ['한국어', '조선말', '韓國語', 'ko', 'Korean'], 'pt-BR': ['Português do Brasil', 'Brasil', 'pt-BR', 'Brazilian Portuguese'], 'ro': ['român', 'limba română', 'ro', 'Romainian'], + 'tr': ['Türkçe', 'tr', 'Turkish'], 'zh-CN': ['简体中文', 'zh-CN', 'zh', 'Chinease'], }) MNEMONIC_LANG_OPTIONS = _add_index_to_options({ From 7371d699b55db6b39766a9d4a07d78a604751076 Mon Sep 17 00:00:00 2001 From: Hsiao-Wei Wang Date: Mon, 1 Aug 2022 16:01:56 +0800 Subject: [PATCH 45/56] Revert "Replace backslashes with forwardslashes" --- README.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index b253147c..d5264b58 100644 --- a/README.md +++ b/README.md @@ -456,7 +456,7 @@ For the [virtualenv](https://virtualenv.pypa.io/en/latest/) users, you can creat ```cmd pip3 install virtualenv virtualenv venv -./venv/Scripts/activate +.\venv\Scripts\activate ``` and install the dependencies: @@ -471,23 +471,23 @@ pip3 install -r requirements.txt Run one of the following command to enter the interactive CLI: ```cmd -python ./staking_deposit/deposit.py new-mnemonic +python .\staking_deposit\deposit.py new-mnemonic ``` or ```cmd -python ./staking_deposit/deposit.py existing-mnemonic +python .\staking_deposit\deposit.py existing-mnemonic ``` You can also run the tool with optional arguments: ```cmd -python ./staking_deposit/deposit.py new-mnemonic --num_validators= --mnemonic_language=english --chain= --folder= +python .\staking_deposit\deposit.py new-mnemonic --num_validators= --mnemonic_language=english --chain= --folder= ``` ```cmd -python ./staking_deposit/deposit.pyexisting-mnemonic --num_validators= --validator_start_index= --chain= --folder= +python .\staking_deposit\deposit.pyexisting-mnemonic --num_validators= --validator_start_index= --chain= --folder= ``` ###### Language Argument From 7007a5fb1ec89fdb6b65a3482c28715ecd847d3d Mon Sep 17 00:00:00 2001 From: Hsiao-Wei Wang Date: Fri, 10 Jun 2022 22:55:15 +0800 Subject: [PATCH 46/56] Add Sepolia support and remove Kintsugi support --- staking_deposit/settings.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/staking_deposit/settings.py b/staking_deposit/settings.py index a38fb836..a908d60d 100644 --- a/staking_deposit/settings.py +++ b/staking_deposit/settings.py @@ -14,6 +14,7 @@ class BaseChainSetting(NamedTuple): GOERLI = 'goerli' PRATER = 'prater' KILN = 'kiln' +SEPOLIA = 'sepolia' # Mainnet setting @@ -24,6 +25,8 @@ class BaseChainSetting(NamedTuple): GoerliSetting = BaseChainSetting(NETWORK_NAME=GOERLI, GENESIS_FORK_VERSION=bytes.fromhex('00001020')) # Merge Testnet (spec v1.1.9) KilnSetting = BaseChainSetting(NETWORK_NAME=KILN, GENESIS_FORK_VERSION=bytes.fromhex('70000069')) +# Sepolia setting +SepoliaSetting = BaseChainSetting(NETWORK_NAME=SEPOLIA, GENESIS_FORK_VERSION=bytes.fromhex('90000069')) ALL_CHAINS: Dict[str, BaseChainSetting] = { @@ -32,6 +35,7 @@ class BaseChainSetting(NamedTuple): GOERLI: GoerliSetting, PRATER: GoerliSetting, # Prater is the old name of the Prater/Goerli testnet KILN: KilnSetting, + SEPOLIA: SepoliaSetting, } From bc7940b2d67f6dd38adb64b4709f34cf0ced4aab Mon Sep 17 00:00:00 2001 From: Ale Banzas Date: Tue, 15 Nov 2022 10:49:02 +0100 Subject: [PATCH 47/56] removing unused networks --- staking_deposit/settings.py | 8 -------- 1 file changed, 8 deletions(-) diff --git a/staking_deposit/settings.py b/staking_deposit/settings.py index db7ddbf6..6b4c33b0 100644 --- a/staking_deposit/settings.py +++ b/staking_deposit/settings.py @@ -14,10 +14,8 @@ class BaseChainSetting(NamedTuple): PRATER = 'prater' KINTSUGI = 'kintsugi' KILN = 'kiln' -GNOSIS_TESTNET = 'gnosis-testnet' GNOSIS = 'gnosis' CHIADO = 'chiado' -TEST = 'test' # Mainnet setting @@ -29,25 +27,19 @@ class BaseChainSetting(NamedTuple): # Merge Testnet (spec v1.1.9) KilnSetting = BaseChainSetting(NETWORK_NAME=KILN, GENESIS_FORK_VERSION=bytes.fromhex('70000069')) -# Gnosis Beacon Chain testnet setting -GnosisTestnetSetting = BaseChainSetting(NETWORK_NAME=GNOSIS_TESTNET, GENESIS_FORK_VERSION=bytes.fromhex('00006464')) # Gnosis Chiado testnet setting (10200) GnosisChiadoTestnetSetting = BaseChainSetting(NETWORK_NAME=CHIADO, GENESIS_FORK_VERSION=bytes.fromhex('000027D8')) # Gnosis Beacon Chain setting (100) GnosisSetting = BaseChainSetting(NETWORK_NAME=GNOSIS, GENESIS_FORK_VERSION=bytes.fromhex('00000064')) -TestSetting = BaseChainSetting(NETWORK_NAME=TEST, GENESIS_FORK_VERSION=bytes.fromhex(environ.get('GENESIS_FORK_VERSION', '12345678'))) - ALL_CHAINS: Dict[str, BaseChainSetting] = { MAINNET: MainnetSetting, PRATER: PraterSetting, KINTSUGI: KintsugiSetting, KILN: KilnSetting, - GNOSIS_TESTNET: GnosisTestnetSetting, GNOSIS: GnosisSetting, CHIADO: GnosisChiadoTestnetSetting, - TEST: TestSetting, } From 11727d923fb4c16ddc8eb81325d9ccdeb42c468f Mon Sep 17 00:00:00 2001 From: Kirill Fedoseev Date: Sat, 17 Jul 2021 17:54:49 +0300 Subject: [PATCH 48/56] Adopt for the Gnosis Beacon Chain --- .github/workflows/ci.yml | 87 ++++++++++++++++++++++++++++ README.md | 30 +++++----- staking_deposit/cli/generate_keys.py | 13 ++++- staking_deposit/settings.py | 14 +++++ 4 files changed, 126 insertions(+), 18 deletions(-) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 00000000..5a2f034b --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,87 @@ +name: CI + +on: + push: + +env: + DOCKER_REGISTRY: ghcr.io + DOCKER_IMAGE_NAME: ${{ github.repository }} + +jobs: + build-docker: + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v2 + + - name: Login to GitHub Container Registry + uses: docker/login-action@v1 + with: + registry: ${{ env.DOCKER_REGISTRY }} + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + + - name: Extract metadata (tags, labels) for Docker + id: meta + uses: docker/metadata-action@v3 + with: + images: ${{ env.DOCKER_REGISTRY }}/${{ env.DOCKER_IMAGE_NAME }} + + - name: Setup buildx + uses: docker/setup-buildx-action@v1 + - name: Fixup buildx + run: docker run --rm --privileged multiarch/qemu-user-static --reset -p yes + - name: Build and push Docker image + uses: docker/build-push-action@v2 + with: + context: . + platforms: 'linux/amd64,linux/arm64,linux/arm/v7' + push: ${{ startsWith(github.ref, 'refs/tags') }} + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} + build-native: + runs-on: ${{ matrix.runner }} + strategy: + fail-fast: false + matrix: + include: + - os: linux + runner: ubuntu-latest + - os: macos + runner: macos-10.15 + - os: windows + runner: windows-latest + env: + PYTHONHASHSEED: 42 + BUILD_FILE_NAME: deposit-cli-${{ github.sha }}-${{ matrix.os }}-amd64 + steps: + - name: Checkout repository + uses: actions/checkout@v2 + - name: Set up Python + uses: actions/setup-python@v2 + with: + python-version: 3.8 + architecture: x64 + - name: Install building requirements on ${{ matrix.os }} + run: | + pip3 install -r ./build_configs/${{ matrix.os }}/requirements.txt; + - name: Build with build.spec + run: | + mkdir ${{ env.BUILD_FILE_NAME }}; + pyinstaller --distpath ./${{ env.BUILD_FILE_NAME }} ./build_configs/${{ matrix.os }}/build.spec; + - name: Compress the file + run: | + tar -zcvf ${{ env.BUILD_FILE_NAME }}.tar.gz ./${{ env.BUILD_FILE_NAME }}; + mkdir /tmp/artifacts; + cp ${{ env.BUILD_FILE_NAME }}.tar.gz /tmp/artifacts; + - name: Save checksum + if: ${{ matrix.os != 'macos' }} + run: sha256sum ${{ env.BUILD_FILE_NAME }}.tar.gz | head -c 64 > /tmp/artifacts/${{ env.BUILD_FILE_NAME }}.sha256 + - name: Save checksum + if: ${{ matrix.os == 'macos' }} + run: shasum -a 256 ${{ env.BUILD_FILE_NAME }}.tar.gz | head -c 64 > /tmp/artifacts/${{ env.BUILD_FILE_NAME }}.sha256 + - name: Upload binary + uses: actions/upload-artifact@v2 + with: + name: ${{ matrix.os }} + path: /tmp/artifacts diff --git a/README.md b/README.md index eec5bd7b..10d97335 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,4 @@ -# staking-deposit-cli - -[![GitPOAP Badge](https://public-api.gitpoap.io/v1/repo/ethereum/staking-deposit-cli/badge)](https://www.gitpoap.io/gh/ethereum/staking-deposit-cli) +# Gnosis Chain validator's data generator @@ -70,7 +68,9 @@ ## Introduction -`deposit-cli` is a tool for creating [EIP-2335 format](https://eips.ethereum.org/EIPS/eip-2335) BLS12-381 keystores and a corresponding `deposit_data*.json` file for [Ethereum Staking Launchpad](https://github.com/ethereum/staking-launchpad). +`validator-data-generator` is a tool for creating [EIP-2335 format](https://eips.ethereum.org/EIPS/eip-2335) BLS12-381 keystores and a corresponding `deposit_data*.json` file for the Gnosis Chain. + +It is based on the [Ethereum `deposit-cli` tool](https://github.com/ethereum/staking-deposit-cli) with minor adoptation for the Gnosis Chain specific. - **Warning: Please generate your keystores on your own safe, completely offline device.** - **Warning: Please backup your mnemonic, keystores, and password securely.** @@ -96,7 +96,7 @@ On Unix-based systems, keystores and the `deposit_data*.json` have `440`/`-r--r- ##### Step 1. Installation -See [releases page](https://github.com/ethereum/staking-deposit-cli/releases) to download and decompress the corresponding binary files. +See [releases page](https://github.com/gnosischain/validator-data-generator/releases) to download and decompress the corresponding binary files. ##### Step 2. Create keys and `deposit_data-*.json` @@ -127,7 +127,7 @@ The CLI offers different commands depending on what you want to do with the tool | Command | Description | | ------- | ----------- | | `new-mnemonic` | (Recommended) This command is used to generate keystores with a new mnemonic. | -| `existing-mnemonic` | This command is used to re-generate or derive new keys from your existing mnemonic. Use this command, if (i) you have already generated keys with this CLI before, (ii) you want to reuse your mnemonic that you know is secure that you generated elsewhere (reusing your eth1 mnemonic .etc), or (iii) you lost your keystores and need to recover your keys. | +| `existing-mnemonic` | This command is used to re-generate or derive new keys from your existing mnemonic. Use this command, if (i) you have already generated keys with this CLI before, (ii) you want to reuse your mnemonic that you know is secure that you generated elsewhere (reusing your gnosis mnemonic .etc), or (iii) you lost your keystores and need to recover your keys. | ###### `new-mnemonic` Arguments @@ -138,8 +138,8 @@ You can use `new-mnemonic --help` to see all arguments. Note that if there are m | `--num_validators` | Non-negative integer | The number of signing keys you want to generate. Note that the child key(s) are generated via the same master key. | | `--mnemonic_language` | String. Options: `简体中文`, `繁體中文`, `český jazyk`, `English`, `Italiano`, `한국어`, `Português`, `Español`. Default to `English` | The mnemonic language | | `--folder` | String. Pointing to `./validator_keys` by default | The folder path for the keystore(s) and deposit(s) | -| `--chain` | String. `mainnet` by default | The chain setting for the signing domain. | -| `--eth1_withdrawal_address` | String. Eth1 address in hexadecimal encoded form | If this field is set and valid, the given Eth1 address will be used to create the withdrawal credentials. Otherwise, it will generate withdrawal credentials with the mnemonic-derived withdrawal public key in [EIP-2334 format](https://eips.ethereum.org/EIPS/eip-2334#eth2-specific-parameters). | +| `--chain` | String. `gnosis` by default | The chain setting for the signing domain. | +| `--eth1_withdrawal_address` | String. Gnosis address in hexadecimal encoded form | If this field is set and valid, the given Gnosis address will be used to create the withdrawal credentials. Otherwise, it will generate withdrawal credentials with the mnemonic-derived withdrawal public key in [EIP-2334 format](https://eips.ethereum.org/EIPS/eip-2334#eth2-specific-parameters). | ###### `existing-mnemonic` Arguments @@ -151,7 +151,7 @@ You can use `existing-mnemonic --help` to see all arguments. Note that if there | `--num_validators` | Non-negative integer | The number of new signing keys you want to generate. Note that the child key(s) are generated via the same master key. | | `--folder` | String. Pointing to `./validator_keys` by default | The folder path for the keystore(s) and deposit(s) | | `--chain` | String. `mainnet` by default | The chain setting for the signing domain. | -| `--eth1_withdrawal_address` | String. Eth1 address in hexadecimal encoded form | If this field is set and valid, the given Eth1 address will be used to create the withdrawal credentials. Otherwise, it will generate withdrawal credentials with the mnemonic-derived withdrawal public key in [EIP-2334 format](https://eips.ethereum.org/EIPS/eip-2334#eth2-specific-parameters). | +| `--eth1_withdrawal_address` | String. Gnosis address in hexadecimal encoded form | If this field is set and valid, the given Gnosis address will be used to create the withdrawal credentials. Otherwise, it will generate withdrawal credentials with the mnemonic-derived withdrawal public key in [EIP-2334 format](https://eips.ethereum.org/EIPS/eip-2334#eth2-specific-parameters). | ###### Successful message @@ -311,19 +311,19 @@ make build_docker Run the following command to enter the interactive CLI: ```sh -docker run -it --rm -v $(pwd)/validator_keys:/app/validator_keys ethereum/staking-deposit-cli +docker run -it --rm -v $(pwd)/validator_keys:/app/validator_keys ghcr.io/gnosischain/validator-data-generator:latest ``` You can also run the tool with optional arguments: ```sh -docker run -it --rm -v $(pwd)/validator_keys:/app/validator_keys ethereum/staking-deposit-cli new-mnemonic --num_validators= --mnemonic_language=english --folder= +docker run -it --rm -v $(pwd)/validator_keys:/app/validator_keys ghcr.io/gnosischain/validator-data-generator:latest new-mnemonic --num_validators= --mnemonic_language=english --folder= ``` -Example for 1 validator on the [Prater testnet](https://prater.launchpad.ethereum.org/) using english: +Example for 1 validator on the [Gnosis](https://docs.gnosischain.com/) using english: ```sh -docker run -it --rm -v $(pwd)/validator_keys:/app/validator_keys ethereum/staking-deposit-cli new-mnemonic --num_validators=1 --mnemonic_language=english --chain=prater +docker run -it --rm -v $(pwd)/validator_keys:/app/validator_keys ghcr.io/gnosischain/validator-data-generator:latest new-mnemonic --num_validators=1 --mnemonic_language=english --chain=gnosis ``` ###### Arguments @@ -340,7 +340,7 @@ See [here](#successful-message) ##### Step 1. Installation -See [releases page](https://github.com/ethereum/staking-deposit-cli/releases) to download and decompress the corresponding binary files. +See [releases page](https://github.com/gnosischain/validator-data-generator/releases) to download and decompress the corresponding binary files. ##### Step 2. Create keys and `deposit_data-*.json` @@ -534,4 +534,4 @@ python3 -m pytest . If you are trying to **build the binary** on macos with an M1 Mac and you are using pyenv to manage your python version. You'll probably need to reinstall a given python version using: ``` env PYTHON_CONFIGURE_OPTS="--enable-framework" pyenv install 3.10.3 -``` +``` \ No newline at end of file diff --git a/staking_deposit/cli/generate_keys.py b/staking_deposit/cli/generate_keys.py index 4caa3b7b..4613c7be 100644 --- a/staking_deposit/cli/generate_keys.py +++ b/staking_deposit/cli/generate_keys.py @@ -35,6 +35,7 @@ ALL_CHAINS, MAINNET, PRATER, + GNOSIS, get_chain_setting, ) @@ -83,7 +84,7 @@ def generate_keys_arguments_decorator(function: Callable[..., Any]) -> Callable[ list(ALL_CHAINS.keys()) ), ), - default=MAINNET, + default=GNOSIS, help=lambda: load_text(['chain', 'help'], func='generate_keys_arguments_decorator'), param_decls='--chain', prompt=choice_prompt_func( @@ -111,6 +112,12 @@ def generate_keys_arguments_decorator(function: Callable[..., Any]) -> Callable[ help=lambda: load_text(['eth1_withdrawal_address', 'help'], func='generate_keys_arguments_decorator'), param_decls='--eth1_withdrawal_address', ), + jit_option( + callback=lambda ctx,param,x: int(x), + default=MAX_DEPOSIT_AMOUNT, + help=('Amount to use in all deposit data files.'), + param_decls='--amount', + ), ] for decorator in reversed(decorators): function = decorator(function) @@ -121,10 +128,10 @@ def generate_keys_arguments_decorator(function: Callable[..., Any]) -> Callable[ @click.pass_context def generate_keys(ctx: click.Context, validator_start_index: int, num_validators: int, folder: str, chain: str, keystore_password: str, - eth1_withdrawal_address: HexAddress, **kwargs: Any) -> None: + amount: int, eth1_withdrawal_address: HexAddress, **kwargs: Any) -> None: mnemonic = ctx.obj['mnemonic'] mnemonic_password = ctx.obj['mnemonic_password'] - amounts = [MAX_DEPOSIT_AMOUNT] * num_validators + amounts = [amount] * num_validators folder = os.path.join(folder, DEFAULT_VALIDATOR_KEYS_FOLDER_NAME) chain_setting = get_chain_setting(chain) if not os.path.exists(folder): diff --git a/staking_deposit/settings.py b/staking_deposit/settings.py index 3f09010e..e38d6a77 100644 --- a/staking_deposit/settings.py +++ b/staking_deposit/settings.py @@ -1,4 +1,5 @@ from typing import Dict, NamedTuple +from os import environ DEPOSIT_CLI_VERSION = '2.3.0' @@ -15,6 +16,9 @@ class BaseChainSetting(NamedTuple): PRATER = 'prater' KILN = 'kiln' SEPOLIA = 'sepolia' +GNOSIS_TESTNET = 'gnosis-testnet' +GNOSIS = 'gnosis' +TEST = 'test' # Mainnet setting @@ -28,6 +32,13 @@ class BaseChainSetting(NamedTuple): # Sepolia setting SepoliaSetting = BaseChainSetting(NETWORK_NAME=SEPOLIA, GENESIS_FORK_VERSION=bytes.fromhex('90000069')) +# Gnosis Beacon Chain testnet setting +GnosisTestnetSetting = BaseChainSetting(NETWORK_NAME=GNOSIS_TESTNET, GENESIS_FORK_VERSION=bytes.fromhex('00006464')) +# Gnosis Beacon Chain setting +GnosisSetting = BaseChainSetting(NETWORK_NAME=GNOSIS, GENESIS_FORK_VERSION=bytes.fromhex('00000064')) + +TestSetting = BaseChainSetting(NETWORK_NAME=TEST, GENESIS_FORK_VERSION=bytes.fromhex(environ.get('GENESIS_FORK_VERSION', '12345678'))) + ALL_CHAINS: Dict[str, BaseChainSetting] = { MAINNET: MainnetSetting, @@ -36,6 +47,9 @@ class BaseChainSetting(NamedTuple): PRATER: GoerliSetting, # Prater is the old name of the Prater/Goerli testnet KILN: KilnSetting, SEPOLIA: SepoliaSetting, + GNOSIS_TESTNET: GnosisTestnetSetting, + GNOSIS: GnosisSetting, + TEST: TestSetting, } From 2ac6b6cb9e173bce61efb4d3e6e306bbbd5140ce Mon Sep 17 00:00:00 2001 From: Alexander Kolotov Date: Wed, 16 Feb 2022 21:55:40 +0300 Subject: [PATCH 49/56] Actualization of README after introduction of executables support (#5) --- Makefile | 2 +- README.md | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index aa118b17..05780350 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ VENV_NAME?=venv VENV_ACTIVATE=. $(VENV_NAME)/bin/activate PYTHON=${VENV_NAME}/bin/python3.8 -DOCKER_IMAGE="ethereum/staking-deposit-cli:latest" +DOCKER_IMAGE="ghcr.io/gnosischain/validator-data-generator:latest" help: @echo "clean - remove build and Python file artifacts" diff --git a/README.md b/README.md index 10d97335..2dad75ef 100644 --- a/README.md +++ b/README.md @@ -323,7 +323,7 @@ docker run -it --rm -v $(pwd)/validator_keys:/app/validator_keys ghcr.io/gnosisc Example for 1 validator on the [Gnosis](https://docs.gnosischain.com/) using english: ```sh -docker run -it --rm -v $(pwd)/validator_keys:/app/validator_keys ghcr.io/gnosischain/validator-data-generator:latest new-mnemonic --num_validators=1 --mnemonic_language=english --chain=gnosis +docker run -it --rm -v $(pwd)/validator_keys:/app/validator_keys ghcr.io/gnosischain/validator-data-generator:latest new-mnemonic --num_validators=1 --mnemonic_language=english ``` ###### Arguments @@ -534,4 +534,4 @@ python3 -m pytest . If you are trying to **build the binary** on macos with an M1 Mac and you are using pyenv to manage your python version. You'll probably need to reinstall a given python version using: ``` env PYTHON_CONFIGURE_OPTS="--enable-framework" pyenv install 3.10.3 -``` \ No newline at end of file +``` From a742790c67f2202c552594aa4537d0a413c5bb55 Mon Sep 17 00:00:00 2001 From: riccardo Date: Fri, 30 Sep 2022 10:11:34 +0200 Subject: [PATCH 50/56] add: chiado in network settings --- staking_deposit/settings.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/staking_deposit/settings.py b/staking_deposit/settings.py index e38d6a77..2f8b04c3 100644 --- a/staking_deposit/settings.py +++ b/staking_deposit/settings.py @@ -18,6 +18,7 @@ class BaseChainSetting(NamedTuple): SEPOLIA = 'sepolia' GNOSIS_TESTNET = 'gnosis-testnet' GNOSIS = 'gnosis' +CHIADO = 'chiado' TEST = 'test' @@ -34,7 +35,9 @@ class BaseChainSetting(NamedTuple): # Gnosis Beacon Chain testnet setting GnosisTestnetSetting = BaseChainSetting(NETWORK_NAME=GNOSIS_TESTNET, GENESIS_FORK_VERSION=bytes.fromhex('00006464')) -# Gnosis Beacon Chain setting +# Gnosis Chiado testnet setting (10200) +GnosisChiadoTestnetSetting = BaseChainSetting(NETWORK_NAME=CHIADO, GENESIS_FORK_VERSION=bytes.fromhex('000027D8')) +# Gnosis Beacon Chain setting (100) GnosisSetting = BaseChainSetting(NETWORK_NAME=GNOSIS, GENESIS_FORK_VERSION=bytes.fromhex('00000064')) TestSetting = BaseChainSetting(NETWORK_NAME=TEST, GENESIS_FORK_VERSION=bytes.fromhex(environ.get('GENESIS_FORK_VERSION', '12345678'))) @@ -49,6 +52,7 @@ class BaseChainSetting(NamedTuple): SEPOLIA: SepoliaSetting, GNOSIS_TESTNET: GnosisTestnetSetting, GNOSIS: GnosisSetting, + CHIADO: GnosisChiadoTestnetSetting, TEST: TestSetting, } From 9e44f827947d0fadaf986c89ef32517e01563cd9 Mon Sep 17 00:00:00 2001 From: Ale Banzas Date: Tue, 15 Nov 2022 10:49:02 +0100 Subject: [PATCH 51/56] removing unused networks --- staking_deposit/settings.py | 6 ------ 1 file changed, 6 deletions(-) diff --git a/staking_deposit/settings.py b/staking_deposit/settings.py index 2f8b04c3..7c87cec1 100644 --- a/staking_deposit/settings.py +++ b/staking_deposit/settings.py @@ -19,7 +19,6 @@ class BaseChainSetting(NamedTuple): GNOSIS_TESTNET = 'gnosis-testnet' GNOSIS = 'gnosis' CHIADO = 'chiado' -TEST = 'test' # Mainnet setting @@ -33,15 +32,11 @@ class BaseChainSetting(NamedTuple): # Sepolia setting SepoliaSetting = BaseChainSetting(NETWORK_NAME=SEPOLIA, GENESIS_FORK_VERSION=bytes.fromhex('90000069')) -# Gnosis Beacon Chain testnet setting -GnosisTestnetSetting = BaseChainSetting(NETWORK_NAME=GNOSIS_TESTNET, GENESIS_FORK_VERSION=bytes.fromhex('00006464')) # Gnosis Chiado testnet setting (10200) GnosisChiadoTestnetSetting = BaseChainSetting(NETWORK_NAME=CHIADO, GENESIS_FORK_VERSION=bytes.fromhex('000027D8')) # Gnosis Beacon Chain setting (100) GnosisSetting = BaseChainSetting(NETWORK_NAME=GNOSIS, GENESIS_FORK_VERSION=bytes.fromhex('00000064')) -TestSetting = BaseChainSetting(NETWORK_NAME=TEST, GENESIS_FORK_VERSION=bytes.fromhex(environ.get('GENESIS_FORK_VERSION', '12345678'))) - ALL_CHAINS: Dict[str, BaseChainSetting] = { MAINNET: MainnetSetting, @@ -53,7 +48,6 @@ class BaseChainSetting(NamedTuple): GNOSIS_TESTNET: GnosisTestnetSetting, GNOSIS: GnosisSetting, CHIADO: GnosisChiadoTestnetSetting, - TEST: TestSetting, } From 22a78c5bd585abcaa48f02f3d7a446a01da8a3fc Mon Sep 17 00:00:00 2001 From: Ale Banzas Date: Tue, 15 Nov 2022 11:22:38 +0100 Subject: [PATCH 52/56] removing unused network --- staking_deposit/settings.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/staking_deposit/settings.py b/staking_deposit/settings.py index 7c87cec1..279dcd96 100644 --- a/staking_deposit/settings.py +++ b/staking_deposit/settings.py @@ -16,7 +16,6 @@ class BaseChainSetting(NamedTuple): PRATER = 'prater' KILN = 'kiln' SEPOLIA = 'sepolia' -GNOSIS_TESTNET = 'gnosis-testnet' GNOSIS = 'gnosis' CHIADO = 'chiado' @@ -45,7 +44,6 @@ class BaseChainSetting(NamedTuple): PRATER: GoerliSetting, # Prater is the old name of the Prater/Goerli testnet KILN: KilnSetting, SEPOLIA: SepoliaSetting, - GNOSIS_TESTNET: GnosisTestnetSetting, GNOSIS: GnosisSetting, CHIADO: GnosisChiadoTestnetSetting, } From c81d15c82f803728ef5c9365c66fbbc512ceebe0 Mon Sep 17 00:00:00 2001 From: Ale Banzas Date: Tue, 15 Nov 2022 11:25:49 +0100 Subject: [PATCH 53/56] fixing chiado fork_version --- staking_deposit/settings.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/staking_deposit/settings.py b/staking_deposit/settings.py index 279dcd96..f2a3af33 100644 --- a/staking_deposit/settings.py +++ b/staking_deposit/settings.py @@ -32,7 +32,7 @@ class BaseChainSetting(NamedTuple): SepoliaSetting = BaseChainSetting(NETWORK_NAME=SEPOLIA, GENESIS_FORK_VERSION=bytes.fromhex('90000069')) # Gnosis Chiado testnet setting (10200) -GnosisChiadoTestnetSetting = BaseChainSetting(NETWORK_NAME=CHIADO, GENESIS_FORK_VERSION=bytes.fromhex('000027D8')) +GnosisChiadoTestnetSetting = BaseChainSetting(NETWORK_NAME=CHIADO, GENESIS_FORK_VERSION=bytes.fromhex('0000006F')) # Gnosis Beacon Chain setting (100) GnosisSetting = BaseChainSetting(NETWORK_NAME=GNOSIS, GENESIS_FORK_VERSION=bytes.fromhex('00000064')) From 05eb5bb8a1d9451069894bac69c47f6c903b57af Mon Sep 17 00:00:00 2001 From: Ale Banzas Date: Tue, 15 Nov 2022 11:40:23 +0100 Subject: [PATCH 54/56] minor fix --- staking_deposit/cli/generate_keys.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/staking_deposit/cli/generate_keys.py b/staking_deposit/cli/generate_keys.py index b1e4e2a5..d35943c7 100644 --- a/staking_deposit/cli/generate_keys.py +++ b/staking_deposit/cli/generate_keys.py @@ -34,8 +34,8 @@ from staking_deposit.settings import ( ALL_CHAINS, GNOSIS, - GNOSIS, CHIADO, + get_chain_setting, ) From 61ce7ca1e95fc952df879d438c5b3d8f489c060b Mon Sep 17 00:00:00 2001 From: Ale Banzas Date: Tue, 15 Nov 2022 11:43:38 +0100 Subject: [PATCH 55/56] fix merge error --- staking_deposit/settings.py | 7 ------- 1 file changed, 7 deletions(-) diff --git a/staking_deposit/settings.py b/staking_deposit/settings.py index 2364ce93..945f8493 100644 --- a/staking_deposit/settings.py +++ b/staking_deposit/settings.py @@ -30,18 +30,11 @@ class BaseChainSetting(NamedTuple): KilnSetting = BaseChainSetting(NETWORK_NAME=KILN, GENESIS_FORK_VERSION=bytes.fromhex('70000069')) # Sepolia setting SepoliaSetting = BaseChainSetting(NETWORK_NAME=SEPOLIA, GENESIS_FORK_VERSION=bytes.fromhex('90000069')) - # Gnosis Chiado testnet setting (10200) GnosisChiadoTestnetSetting = BaseChainSetting(NETWORK_NAME=CHIADO, GENESIS_FORK_VERSION=bytes.fromhex('0000006F')) # Gnosis Beacon Chain setting (100) GnosisSetting = BaseChainSetting(NETWORK_NAME=GNOSIS, GENESIS_FORK_VERSION=bytes.fromhex('00000064')) -# Gnosis Chiado testnet setting (10200) -GnosisChiadoTestnetSetting = BaseChainSetting(NETWORK_NAME=CHIADO, GENESIS_FORK_VERSION=bytes.fromhex('000027D8')) -# Gnosis Beacon Chain setting (100) -GnosisSetting = BaseChainSetting(NETWORK_NAME=GNOSIS, GENESIS_FORK_VERSION=bytes.fromhex('00000064')) - - ALL_CHAINS: Dict[str, BaseChainSetting] = { MAINNET: MainnetSetting, ROPSTEN: RopstenSetting, From f9553f5ce8dddf8ecb948867d5a7d9419892b446 Mon Sep 17 00:00:00 2001 From: Ale Banzas Date: Tue, 15 Nov 2022 14:35:53 +0100 Subject: [PATCH 56/56] fix --- staking_deposit/cli/generate_keys.py | 1 + 1 file changed, 1 insertion(+) diff --git a/staking_deposit/cli/generate_keys.py b/staking_deposit/cli/generate_keys.py index d35943c7..cc5eec89 100644 --- a/staking_deposit/cli/generate_keys.py +++ b/staking_deposit/cli/generate_keys.py @@ -33,6 +33,7 @@ ) from staking_deposit.settings import ( ALL_CHAINS, + PRATER, GNOSIS, CHIADO, get_chain_setting,