From 0c9584393c9b74d66bf7293755a5060bdd775f1b Mon Sep 17 00:00:00 2001 From: "Felix C. Morency" <1102868+fmorency@users.noreply.github.com> Date: Mon, 5 Aug 2024 13:52:59 -0400 Subject: [PATCH] chore!: bump poa module to `d321226` - POA params were removed in `d321226` - `GetPoAAdmin()` now panics if `POA_ADMIN_ADDRESS` is not set - Fix tests, parameters and documentation to reflect the update --- app/app.go | 9 ++-- app/test_helpers.go | 8 +++ chains/chain.json | 7 --- go.mod | 18 +++---- go.sum | 36 +++++++------- interchaintest/go.mod | 14 +++--- interchaintest/go.sum | 28 +++++------ interchaintest/mainfest_test.go | 3 -- interchaintest/poa_group_test.go | 62 +----------------------- interchaintest/setup.go | 9 ++-- network/manifest-1/README.md | 7 ++- network/manifest-1/genesis.json | 22 +++------ network/manifest-1/set-genesis-params.sh | 2 - scripts/test_node.sh | 5 +- 14 files changed, 78 insertions(+), 152 deletions(-) diff --git a/app/app.go b/app/app.go index 9db7d1b..951348e 100644 --- a/app/app.go +++ b/app/app.go @@ -141,13 +141,11 @@ import ( ) func GetPoAAdmin() string { - // used only in e2e testing with interchaintest - if address := os.Getenv("POA_ADMIN_ADDRESS"); address != "" { - return address + if addr := os.Getenv("POA_ADMIN_ADDRESS"); addr != "" { + return addr } - // !IMPORTANT: testnet only (reece's addr). Change this to a mainnet address - return "manifest10r39fueph9fq7a6lgswu4zdsg8t3gxlqdwwncm" + panic("POA_ADMIN_ADDRESS environment variable not set") } // We pull these out so we can set them with LDFLAGS in the Makefile @@ -438,6 +436,7 @@ func NewApp( app.SlashingKeeper, app.BankKeeper, logger, + GetPoAAdmin(), ) app.POAKeeper.SetTestAccountKeeper(app.AccountKeeper) diff --git a/app/test_helpers.go b/app/test_helpers.go index 5e8019e..7e8f4c6 100644 --- a/app/test_helpers.go +++ b/app/test_helpers.go @@ -8,6 +8,7 @@ import ( "testing" "time" + "github.com/cosmos/cosmos-sdk/testutil/testdata" "github.com/stretchr/testify/require" abci "github.com/cometbft/cometbft/abci/types" @@ -179,6 +180,13 @@ func setup(t *testing.T, withGenesis bool) (*ManifestApp, GenesisState) { appOptions := make(simtestutil.AppOptionsMap, 0) appOptions[flags.FlagHome] = nodeHome // ensure unique folder + // Set the POA admin address if not already set + if adminAddr := os.Getenv("POA_ADMIN_ADDRESS"); adminAddr == "" { + _, _, newAdminAddr := testdata.KeyTestPubAddr() + err = os.Setenv("POA_ADMIN_ADDRESS", newAdminAddr.String()) + require.NoError(t, err) + } + app := NewApp( log.NewNopLogger(), db, diff --git a/chains/chain.json b/chains/chain.json index 0b9efd7..13310f5 100644 --- a/chains/chain.json +++ b/chains/chain.json @@ -43,13 +43,6 @@ "key": "app_state.gov.params.min_deposit.0.denom", "value": "umfx" }, - { - "key": "app_state.poa.params.admins", - "value": [ - "manifest10d07y265gmmuvt4z0w9aw880jnsr700jmq3jzm", - "manifest1hj5fveer5cjtn4wd6wstzugjfdxzl0xp8ws9ct" - ] - }, { "key": "app_state.tokenfactory.params.denom_creation_fee", "value": [] diff --git a/go.mod b/go.mod index 094c29a..0c2ba3d 100644 --- a/go.mod +++ b/go.mod @@ -14,7 +14,7 @@ replace ( github.com/spf13/viper => github.com/spf13/viper v1.17.0 // v1.18+ breaks app overrides // TODO: Remove this once 0.50.3 is released - github.com/strangelove-ventures/poa => github.com/strangelove-ventures/poa v0.50.3-0.20240720145936-3595e3d47ba0 + github.com/strangelove-ventures/poa => github.com/strangelove-ventures/poa v0.50.3-0.20240805145915-d321226154be // Downgraded to avoid bugs in following commits which caused simulations to fail. github.com/syndtr/goleveldb => github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 @@ -25,7 +25,7 @@ require ( cosmossdk.io/client/v2 v2.0.0-beta.1 cosmossdk.io/collections v0.4.0 cosmossdk.io/core v0.12.0 - cosmossdk.io/depinject v1.0.0-alpha.4 + cosmossdk.io/depinject v1.0.0 cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.3.1 cosmossdk.io/math v1.3.0 @@ -55,7 +55,7 @@ require ( github.com/stretchr/testify v1.9.0 google.golang.org/genproto/googleapis/api v0.0.0-20240528184218-531527333157 google.golang.org/grpc v1.65.0 - google.golang.org/protobuf v1.34.1 + google.golang.org/protobuf v1.34.2 ) require ( @@ -202,18 +202,18 @@ require ( go.opentelemetry.io/otel/metric v1.26.0 // indirect go.opentelemetry.io/otel/trace v1.26.0 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.23.0 // indirect + golang.org/x/crypto v0.25.0 // indirect golang.org/x/exp v0.0.0-20240416160154-fe59bbe5cc7f // indirect - golang.org/x/net v0.25.0 // indirect + golang.org/x/net v0.27.0 // indirect golang.org/x/oauth2 v0.20.0 // indirect golang.org/x/sync v0.7.0 // indirect - golang.org/x/sys v0.20.0 // indirect - golang.org/x/term v0.20.0 // indirect - golang.org/x/text v0.15.0 // indirect + golang.org/x/sys v0.22.0 // indirect + golang.org/x/term v0.22.0 // indirect + golang.org/x/text v0.16.0 // indirect golang.org/x/time v0.5.0 // indirect google.golang.org/api v0.176.1 // indirect google.golang.org/genproto v0.0.0-20240415180920-8c6c420018be // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20240528184218-531527333157 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240709173604-40e1e62336c5 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v2 v2.4.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect diff --git a/go.sum b/go.sum index a40ac44..838cd93 100644 --- a/go.sum +++ b/go.sum @@ -194,8 +194,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.11.0 h1:vtIafqUi+1ZNAE/oxLOQQ7Oek2n4S48SWLG8h/+wdbo= cosmossdk.io/core v0.11.0/go.mod h1:LaTtayWBSoacF5xNzoF8tmLhehqlA9z1SWiPuNC6X1w= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= +cosmossdk.io/depinject v1.0.0 h1:dQaTu6+O6askNXO06+jyeUAnF2/ssKwrrszP9t5q050= +cosmossdk.io/depinject v1.0.0/go.mod h1:zxK/h3HgHoA/eJVtiSsoaRaRA2D5U4cJ5thIG4ssbB8= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.3.1 h1:UZx8nWIkfbbNEWusZqzAx3ZGvu54TZacWib3EzUYmGI= @@ -958,8 +958,8 @@ github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/spf13/viper v1.17.0 h1:I5txKw7MJasPL/BrfkbA0Jyo/oELqVmux4pR/UxOMfI= github.com/spf13/viper v1.17.0/go.mod h1:BmMMMLQXSbcHK6KAOiFLz0l5JHrU89OdIRHvsk0+yVI= -github.com/strangelove-ventures/poa v0.50.3-0.20240720145936-3595e3d47ba0 h1:9h8TJL5qnTrYOyJmT2xQzUrrLv4cfLmgfvTtTUoBmHY= -github.com/strangelove-ventures/poa v0.50.3-0.20240720145936-3595e3d47ba0/go.mod h1:0cOydjyn8T6gZKvLkpXgBYVD636od00GmCddaoOkS2E= +github.com/strangelove-ventures/poa v0.50.3-0.20240805145915-d321226154be h1:uVa7Om1vIhlGwHSndC1GPwxyD/g25FtMHKq3ZsD2pRw= +github.com/strangelove-ventures/poa v0.50.3-0.20240805145915-d321226154be/go.mod h1:hCoBNFkrAxmRvVVXVsaIN8j3jpxzBUxDXZ0LP3NrRyw= github.com/strangelove-ventures/tokenfactory v0.50.3 h1:MccxHYUHjMHDOxcmx/HJs1mU4zVhli1f4sz3126Wzr8= github.com/strangelove-ventures/tokenfactory v0.50.3/go.mod h1:z0hlFofihDchAZxyzu0P/XxM+FSUAC+RmncklvTdcDg= github.com/streadway/amqp v0.0.0-20190404075320-75d898a42a94/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= @@ -1064,8 +1064,8 @@ golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.23.0 h1:dIJU/v2J8Mdglj/8rJ6UUOM3Zc9zLZxVZwwxMooUSAI= -golang.org/x/crypto v0.23.0/go.mod h1:CKFgDieR+mRhux2Lsu27y0fO304Db0wZe70UKqHu0v8= +golang.org/x/crypto v0.25.0 h1:ypSNr+bnYL2YhwoMt2zPxHFmbAN1KZs/njMG3hxUp30= +golang.org/x/crypto v0.25.0/go.mod h1:T+wALwcMOSE0kXgUAnPAHqTLW+XHgcELELW8VaDgm/M= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= @@ -1164,8 +1164,8 @@ golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug golang.org/x/net v0.0.0-20220909164309-bea034e7d591/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk= golang.org/x/net v0.0.0-20221014081412-f15817d10f9b/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk= golang.org/x/net v0.1.0/go.mod h1:Cx3nUiGt4eDBEyega/BKRp+/AlGL8hYe7U9odMt2Cco= -golang.org/x/net v0.25.0 h1:d/OCCoBEUq33pjydKrGQhw7IlUPI2Oylr+8qLx49kac= -golang.org/x/net v0.25.0/go.mod h1:JkAGAh7GEvH74S6FOH42FLoXpXbE/aqXSrIQjXgsiwM= +golang.org/x/net v0.27.0 h1:5K3Njcw06/l2y9vpGCSdcxWOYHOUk3dVNGDXN+FvAys= +golang.org/x/net v0.27.0/go.mod h1:dDi0PyhWNoiUOrAS8uXv/vnScO4wnHQO4mj9fn/RytE= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -1303,13 +1303,13 @@ golang.org/x/sys v0.0.0-20221010170243-090e33056c14/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.20.0 h1:Od9JTbYCk261bKm4M/mw7AklTlFYIa0bIp9BgSm1S8Y= -golang.org/x/sys v0.20.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.22.0 h1:RI27ohtqKCnwULzJLqkv897zojh5/DwS/ENaMzUOaWI= +golang.org/x/sys v0.22.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= -golang.org/x/term v0.20.0 h1:VnkxpohqXaOBYJtBmEppKUG6mXpi+4O6purfc2+sMhw= -golang.org/x/term v0.20.0/go.mod h1:8UkIAJTvZgivsXaD6/pH6U9ecQzZ45awqEOzuCvwpFY= +golang.org/x/term v0.22.0 h1:BbsgPEJULsl2fV/AT3v15Mjva5yXKQDyKf+TbDz7QJk= +golang.org/x/term v0.22.0/go.mod h1:F3qCibpT5AMpCRfhfT53vVJwhLtIVHhB9XDjfFvnMI4= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -1320,8 +1320,8 @@ golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= -golang.org/x/text v0.15.0 h1:h1V/4gjBv8v9cjcR6+AR5+/cIYK5N/WAgiv4xlsEtAk= -golang.org/x/text v0.15.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= +golang.org/x/text v0.16.0 h1:a94ExnEXNtEwYLGJSIUxnWoxoRz/ZcCsV63ROupILh4= +golang.org/x/text v0.16.0/go.mod h1:GhwF1Be+LQoKShO3cGOHzqOgRrGaYc9AvblQOmPVHnI= golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= @@ -1570,8 +1570,8 @@ google.golang.org/genproto v0.0.0-20240415180920-8c6c420018be h1:g4aX8SUFA8V5F4L google.golang.org/genproto v0.0.0-20240415180920-8c6c420018be/go.mod h1:FeSdT5fk+lkxatqJP38MsUicGqHax5cLtmy/6TAuxO4= google.golang.org/genproto/googleapis/api v0.0.0-20240528184218-531527333157 h1:7whR9kGa5LUwFtpLm2ArCEejtnxlGeLbAyjFY8sGNFw= google.golang.org/genproto/googleapis/api v0.0.0-20240528184218-531527333157/go.mod h1:99sLkeliLXfdj2J75X3Ho+rrVCaJze0uwN7zDDkjPVU= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240528184218-531527333157 h1:Zy9XzmMEflZ/MAaA7vNcoebnRAld7FsPW1EeBB7V0m8= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240528184218-531527333157/go.mod h1:EfXuqaE1J41VCDicxHzUDm+8rk+7ZdXzHV0IhO/I6s0= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240709173604-40e1e62336c5 h1:SbSDUWW1PAO24TNpLdeheoYPd7kllICcLU52x6eD4kQ= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240709173604-40e1e62336c5/go.mod h1:Ue6ibwXGpU+dqIcODieyLOcgj7z8+IcskoNIgZxtrFY= google.golang.org/grpc v1.12.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= @@ -1632,8 +1632,8 @@ google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQ google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= google.golang.org/protobuf v1.28.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= google.golang.org/protobuf v1.28.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= -google.golang.org/protobuf v1.34.1 h1:9ddQBjfCyZPOHPUiPxpYESBLc+T8P3E+Vo4IbKZgFWg= -google.golang.org/protobuf v1.34.1/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= +google.golang.org/protobuf v1.34.2 h1:6xV6lTsCfpGD21XK49h7MhtcApnLqkfYgPcdHftf6hg= +google.golang.org/protobuf v1.34.2/go.mod h1:qYOHts0dSfpeUzUFpOMr/WGzszTmLH+DiWniOlNbLDw= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= diff --git a/interchaintest/go.mod b/interchaintest/go.mod index bc787fe..a7b7ded 100644 --- a/interchaintest/go.mod +++ b/interchaintest/go.mod @@ -14,7 +14,7 @@ replace ( github.com/gogo/protobuf => github.com/regen-network/protobuf v1.3.3-alpha.regen.1 github.com/liftedinit/manifest-ledger => ../ // TODO: Remove this once 0.50.3 is released - github.com/strangelove-ventures/poa => github.com/strangelove-ventures/poa v0.50.3-0.20240720145936-3595e3d47ba0 + github.com/strangelove-ventures/poa => github.com/strangelove-ventures/poa v0.50.3-0.20240805145915-d321226154be ) require ( @@ -42,7 +42,7 @@ require ( cosmossdk.io/api v0.7.5 // indirect cosmossdk.io/collections v0.4.0 // indirect cosmossdk.io/core v0.12.0 // indirect - cosmossdk.io/depinject v1.0.0-alpha.4 // indirect + cosmossdk.io/depinject v1.0.0 // indirect cosmossdk.io/errors v1.0.1 // indirect cosmossdk.io/log v1.3.1 // indirect cosmossdk.io/store v1.1.0 // indirect @@ -240,21 +240,21 @@ require ( go.opentelemetry.io/otel/sdk v1.28.0 // indirect go.opentelemetry.io/otel/trace v1.28.0 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.24.0 // indirect + golang.org/x/crypto v0.25.0 // indirect golang.org/x/exp v0.0.0-20240416160154-fe59bbe5cc7f // indirect golang.org/x/mod v0.17.0 // indirect - golang.org/x/net v0.26.0 // indirect + golang.org/x/net v0.27.0 // indirect golang.org/x/oauth2 v0.20.0 // indirect golang.org/x/sync v0.7.0 // indirect - golang.org/x/sys v0.21.0 // indirect - golang.org/x/term v0.21.0 // indirect + golang.org/x/sys v0.22.0 // indirect + golang.org/x/term v0.22.0 // indirect golang.org/x/text v0.16.0 // indirect golang.org/x/time v0.5.0 // indirect golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d // indirect google.golang.org/api v0.176.1 // indirect google.golang.org/genproto v0.0.0-20240415180920-8c6c420018be // indirect google.golang.org/genproto/googleapis/api v0.0.0-20240701130421-f6361c86f094 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20240701130421-f6361c86f094 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240709173604-40e1e62336c5 // indirect google.golang.org/grpc v1.65.0 // indirect google.golang.org/protobuf v1.34.2 // indirect gopkg.in/ini.v1 v1.67.0 // indirect diff --git a/interchaintest/go.sum b/interchaintest/go.sum index 16eb0e6..9d47023 100644 --- a/interchaintest/go.sum +++ b/interchaintest/go.sum @@ -194,8 +194,8 @@ cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= cosmossdk.io/core v0.11.0 h1:vtIafqUi+1ZNAE/oxLOQQ7Oek2n4S48SWLG8h/+wdbo= cosmossdk.io/core v0.11.0/go.mod h1:LaTtayWBSoacF5xNzoF8tmLhehqlA9z1SWiPuNC6X1w= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= +cosmossdk.io/depinject v1.0.0 h1:dQaTu6+O6askNXO06+jyeUAnF2/ssKwrrszP9t5q050= +cosmossdk.io/depinject v1.0.0/go.mod h1:zxK/h3HgHoA/eJVtiSsoaRaRA2D5U4cJ5thIG4ssbB8= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.3.1 h1:UZx8nWIkfbbNEWusZqzAx3ZGvu54TZacWib3EzUYmGI= @@ -1049,8 +1049,8 @@ github.com/spf13/viper v1.18.2 h1:LUXCnvUvSM6FXAsj6nnfc8Q2tp1dIgUfY9Kc8GsSOiQ= github.com/spf13/viper v1.18.2/go.mod h1:EKmWIqdnk5lOcmR72yw6hS+8OPYcwD0jteitLMVB+yk= github.com/strangelove-ventures/interchaintest/v8 v8.5.1-0.20240715163423-cbcd20f44321 h1:uemY7a+M5RWC/6kTSgLql0kBEGKy/zY83p1Ne9kTzjY= github.com/strangelove-ventures/interchaintest/v8 v8.5.1-0.20240715163423-cbcd20f44321/go.mod h1:UPMvR1joIXO8RMxDozoHIInLZWmd2345PSGLJYWyrwY= -github.com/strangelove-ventures/poa v0.50.3-0.20240720145936-3595e3d47ba0 h1:9h8TJL5qnTrYOyJmT2xQzUrrLv4cfLmgfvTtTUoBmHY= -github.com/strangelove-ventures/poa v0.50.3-0.20240720145936-3595e3d47ba0/go.mod h1:0cOydjyn8T6gZKvLkpXgBYVD636od00GmCddaoOkS2E= +github.com/strangelove-ventures/poa v0.50.3-0.20240805145915-d321226154be h1:uVa7Om1vIhlGwHSndC1GPwxyD/g25FtMHKq3ZsD2pRw= +github.com/strangelove-ventures/poa v0.50.3-0.20240805145915-d321226154be/go.mod h1:hCoBNFkrAxmRvVVXVsaIN8j3jpxzBUxDXZ0LP3NrRyw= github.com/strangelove-ventures/tokenfactory v0.50.3 h1:MccxHYUHjMHDOxcmx/HJs1mU4zVhli1f4sz3126Wzr8= github.com/strangelove-ventures/tokenfactory v0.50.3/go.mod h1:z0hlFofihDchAZxyzu0P/XxM+FSUAC+RmncklvTdcDg= github.com/streadway/amqp v0.0.0-20190404075320-75d898a42a94/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= @@ -1178,8 +1178,8 @@ golang.org/x/crypto v0.0.0-20191206172530-e9b2fee46413/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.24.0 h1:mnl8DM0o513X8fdIkmyFE/5hTYxbwYOjDS/+rK6qpRI= -golang.org/x/crypto v0.24.0/go.mod h1:Z1PMYSOR5nyMcyAVAIQSKCDwalqy85Aqn1x3Ws4L5DM= +golang.org/x/crypto v0.25.0 h1:ypSNr+bnYL2YhwoMt2zPxHFmbAN1KZs/njMG3hxUp30= +golang.org/x/crypto v0.25.0/go.mod h1:T+wALwcMOSE0kXgUAnPAHqTLW+XHgcELELW8VaDgm/M= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= @@ -1280,8 +1280,8 @@ golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug golang.org/x/net v0.0.0-20220909164309-bea034e7d591/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk= golang.org/x/net v0.0.0-20221014081412-f15817d10f9b/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk= golang.org/x/net v0.1.0/go.mod h1:Cx3nUiGt4eDBEyega/BKRp+/AlGL8hYe7U9odMt2Cco= -golang.org/x/net v0.26.0 h1:soB7SVo0PWrY4vPW/+ay0jKDNScG2X9wFeYlXIvJsOQ= -golang.org/x/net v0.26.0/go.mod h1:5YKkiSynbBIh3p6iOc/vibscux0x38BZDkn8sCUPxHE= +golang.org/x/net v0.27.0 h1:5K3Njcw06/l2y9vpGCSdcxWOYHOUk3dVNGDXN+FvAys= +golang.org/x/net v0.27.0/go.mod h1:dDi0PyhWNoiUOrAS8uXv/vnScO4wnHQO4mj9fn/RytE= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -1419,13 +1419,13 @@ golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.21.0 h1:rF+pYz3DAGSQAxAu1CbC7catZg4ebC4UIeIhKxBZvws= -golang.org/x/sys v0.21.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.22.0 h1:RI27ohtqKCnwULzJLqkv897zojh5/DwS/ENaMzUOaWI= +golang.org/x/sys v0.22.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= -golang.org/x/term v0.21.0 h1:WVXCp+/EBEHOj53Rvu+7KiT/iElMrO8ACK16SMZ3jaA= -golang.org/x/term v0.21.0/go.mod h1:ooXLefLobQVslOqselCNF4SxFAaoS6KujMbsGzSDmX0= +golang.org/x/term v0.22.0 h1:BbsgPEJULsl2fV/AT3v15Mjva5yXKQDyKf+TbDz7QJk= +golang.org/x/term v0.22.0/go.mod h1:F3qCibpT5AMpCRfhfT53vVJwhLtIVHhB9XDjfFvnMI4= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -1687,8 +1687,8 @@ google.golang.org/genproto v0.0.0-20240415180920-8c6c420018be h1:g4aX8SUFA8V5F4L google.golang.org/genproto v0.0.0-20240415180920-8c6c420018be/go.mod h1:FeSdT5fk+lkxatqJP38MsUicGqHax5cLtmy/6TAuxO4= google.golang.org/genproto/googleapis/api v0.0.0-20240701130421-f6361c86f094 h1:0+ozOGcrp+Y8Aq8TLNN2Aliibms5LEzsq99ZZmAGYm0= google.golang.org/genproto/googleapis/api v0.0.0-20240701130421-f6361c86f094/go.mod h1:fJ/e3If/Q67Mj99hin0hMhiNyCRmt6BQ2aWIJshUSJw= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240701130421-f6361c86f094 h1:BwIjyKYGsK9dMCBOorzRri8MQwmi7mT9rGHsCEinZkA= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240701130421-f6361c86f094/go.mod h1:Ue6ibwXGpU+dqIcODieyLOcgj7z8+IcskoNIgZxtrFY= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240709173604-40e1e62336c5 h1:SbSDUWW1PAO24TNpLdeheoYPd7kllICcLU52x6eD4kQ= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240709173604-40e1e62336c5/go.mod h1:Ue6ibwXGpU+dqIcODieyLOcgj7z8+IcskoNIgZxtrFY= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= diff --git a/interchaintest/mainfest_test.go b/interchaintest/mainfest_test.go index 6d77351..6d079b9 100644 --- a/interchaintest/mainfest_test.go +++ b/interchaintest/mainfest_test.go @@ -24,9 +24,6 @@ func TestManifestModule(t *testing.T) { ctx := context.Background() cfgA := LocalChainConfig - cfgA.Env = []string{ - fmt.Sprintf("POA_ADMIN_ADDRESS=%s", accAddr), - } cfgA.WithCodeCoverage() cf := interchaintest.NewBuiltinChainFactory(zaptest.NewLogger(t, zaptest.Level(zapcore.DebugLevel)), []*interchaintest.ChainSpec{ diff --git a/interchaintest/poa_group_test.go b/interchaintest/poa_group_test.go index 45ee9cb..a0ea26c 100644 --- a/interchaintest/poa_group_test.go +++ b/interchaintest/poa_group_test.go @@ -19,7 +19,6 @@ import ( "github.com/strangelove-ventures/interchaintest/v8/chain/cosmos" "github.com/strangelove-ventures/interchaintest/v8/dockerutil" "github.com/strangelove-ventures/interchaintest/v8/ibc" - poatypes "github.com/strangelove-ventures/poa" tokenfactorytypes "github.com/strangelove-ventures/tokenfactory/x/tokenfactory/types" "github.com/stretchr/testify/require" @@ -68,7 +67,6 @@ var ( ) manifestBurnProposal = createManifestBurnProposal(groupAddr, sdk.NewCoins(sdk.NewInt64Coin(Denom, 50))) - poaDefaultParams = createPOAParams([]string{groupAddr}, true) bankSendProposal = createBankSendProposal(groupAddr, accAddr, sdk.NewInt64Coin(Denom, 1)) tfCreateProposal = createTfCreateDenomProposal(groupAddr, tfDenom) tfMintProposal = createTfMintProposal(groupAddr, sdk.NewInt64Coin(tfFullDenom, 1234), "") @@ -115,7 +113,7 @@ func TestGroupPOA(t *testing.T) { ctx, ic, client, _ := interchaintest.BuildInitialChain(t, chains, false) - user1Wallet, err := interchaintest.GetAndFundTestUserWithMnemonic(ctx, user1, accMnemonic, DefaultGenesisAmt, chain) + _, err = interchaintest.GetAndFundTestUserWithMnemonic(ctx, user1, accMnemonic, DefaultGenesisAmt, chain) require.NoError(t, err) _, err = interchaintest.GetAndFundTestUserWithMnemonic(ctx, user2, acc1Mnemonic, DefaultGenesisAmt, chain) require.NoError(t, err) @@ -124,9 +122,6 @@ func TestGroupPOA(t *testing.T) { testSoftwareUpgrade(t, ctx, chain, &cfgA, accAddr) // Manifest module testManifestStakeholdersPayout(t, ctx, chain, &cfgA, accAddr) - // POA Update - testPOAParamsUpdateEmpty(t, ctx, chain, &cfgA, accAddr) - testPOAParamsUpdate(t, ctx, chain, &cfgA, accAddr, user1Wallet) // TokenFactory testTokenCreate(t, ctx, chain, &cfgA, accAddr) // Bank @@ -191,33 +186,6 @@ func testManifestStakeholdersPayout(t *testing.T, ctx context.Context, chain *co verifyBalance(t, ctx, chain, groupAddr, Denom, sdkmath.ZeroInt()) } -// testPOAParamsUpdateEmpty tests the submission, voting, and execution of an empty POA params update proposal -// This proposal tests that the Admins field cannot be empty -func testPOAParamsUpdateEmpty(t *testing.T, ctx context.Context, chain *cosmos.CosmosChain, config *ibc.ChainConfig, accAddr string) { - t.Log("\n===== TEST GROUP POA PARAMS UPDATE (EMPTY ADMINS - FAIL) =====") - poaUpdateProposal := createPOAUpdateParams(groupAddr, createPOAParams(nil, false)) - createAndRunProposalFailure(t, ctx, chain, config, accAddr, []*types.Any{createAny(t, poaUpdateProposal)}, poatypes.ErrMustProvideAtLeastOneAddress.Error()) - checkPOAParams(ctx, t, chain, &poaDefaultParams) -} - -// testPOAParamsUpdate tests the submission, voting, and execution of a POA params update proposal -func testPOAParamsUpdate(t *testing.T, ctx context.Context, chain *cosmos.CosmosChain, config *ibc.ChainConfig, accAddr string, user ibc.Wallet) { - t.Log("\n===== TEST GROUP POA PARAMS UPDATE =====") - poaUpdateProposal := createPOAUpdateParams(groupAddr, createPOAParams([]string{accAddr}, false)) - createAndRunProposalSuccess(t, ctx, chain, config, accAddr, []*types.Any{createAny(t, poaUpdateProposal)}) - checkPOAParams(ctx, t, chain, &poaUpdateProposal.Params) - - // NOTE: - // At this point, the POA_ADMIN_ADDRESS is still the Group address, but the POA module admin field is now `accAddr` - // What this means is that the POA_ADMIN_ADDRESS is the authority for all CosmosSDK modules, including the Group module, - // but the POA module admin field is the authority for the POA module itself. - - // Reset the POA Admin back to the Group address using the POA module admin field, i.e., `accAddr` - // Resetting the POA Admin back to the Group address using a group proposal will NOT work - updatePOAParams(t, ctx, chain, user, groupAddr, true) - checkPOAParams(ctx, t, chain, &poaDefaultParams) -} - // testBankSend tests the sending of funds from one account to another using a group proposal func testBankSend(t *testing.T, ctx context.Context, chain *cosmos.CosmosChain, config *ibc.ChainConfig, accAddr string) { t.Log("\n===== TEST GROUP BANK SEND =====") @@ -332,19 +300,6 @@ func checkManifestParams(ctx context.Context, t *testing.T, chain *cosmos.Cosmos require.NotNil(t, resp.Params) } -// checkPOAParams checks the POA params against the expected params -func checkPOAParams(ctx context.Context, t *testing.T, chain *cosmos.CosmosChain, expectedParams *poatypes.Params) { - resp, err := poatypes.NewQueryClient(chain.GetNode().GrpcConn).Params(ctx, &poatypes.QueryParamsRequest{}) - require.NoError(t, err) - require.NotNil(t, resp) - require.NotNil(t, resp.Params) - require.Len(t, resp.Params.Admins, len(expectedParams.Admins)) - for i, admin := range expectedParams.Admins { - require.Equal(t, admin, resp.Params.Admins[i]) - } - require.Equal(t, expectedParams.AllowValidatorSelfExit, resp.Params.AllowValidatorSelfExit) -} - // submitVoteAndExecProposal submits, votes, and executes a group proposal func submitVoteAndExecProposal(ctx context.Context, t *testing.T, chain *cosmos.CosmosChain, config *ibc.ChainConfig, keyName string, prop *grouptypes.MsgSubmitProposal) error { // Increment the proposal ID regardless of the outcome @@ -408,7 +363,6 @@ func createGroupGenesis() []cosmos.GenesisKV { cosmos.NewGenesisKV("app_state.group.group_members", []grouptypes.GroupMember{groupMember1, groupMember2}), cosmos.NewGenesisKV("app_state.group.group_policy_seq", "1"), cosmos.NewGenesisKV("app_state.group.group_policies", []*grouptypes.GroupPolicyInfo{groupPolicy}), - cosmos.NewGenesisKV("app_state.poa.params.admins", []string{groupAddr}), ) } @@ -490,20 +444,6 @@ func createManifestBurnProposal(sender string, amounts sdk.Coins) manifesttypes. } } -func createPOAParams(admins []string, allowValidatorSelfExit bool) poatypes.Params { - return poatypes.Params{ - Admins: admins, - AllowValidatorSelfExit: allowValidatorSelfExit, - } -} - -func createPOAUpdateParams(sender string, params poatypes.Params) *poatypes.MsgUpdateParams { - return &poatypes.MsgUpdateParams{ - Sender: sender, - Params: params, - } -} - func createBankSendProposal(from, to string, amount sdk.Coin) banktypes.MsgSend { return banktypes.MsgSend{ FromAddress: from, diff --git a/interchaintest/setup.go b/interchaintest/setup.go index 390b329..1dd3d51 100644 --- a/interchaintest/setup.go +++ b/interchaintest/setup.go @@ -1,6 +1,8 @@ package interchaintest import ( + "fmt" + grouptypes "github.com/cosmos/cosmos-sdk/x/group" poatypes "github.com/strangelove-ventures/poa" tokenfactorytypes "github.com/strangelove-ventures/tokenfactory/x/tokenfactory/types" @@ -34,8 +36,6 @@ var ( acc4Addr = "manifest1g292xgmcclhq4au5p7580m2s3f8tpwjra644jm" acc4Mnemonic = "myself bamboo retire day exile cancel peanut agree come method odor innocent welcome royal engage key surprise practice capable sauce orient young divert mirror" - CosmosGovModuleAcc = "manifest10d07y265gmmuvt4z0w9aw880jnsr700jmq3jzm" - vals = 2 fullNodes = 0 @@ -48,8 +48,6 @@ var ( // TokenFactory cosmos.NewGenesisKV("app_state.tokenfactory.params.denom_creation_fee", nil), cosmos.NewGenesisKV("app_state.tokenfactory.params.denom_creation_gas_consume", "1"), - // PoA - cosmos.NewGenesisKV("app_state.poa.params.admins", []string{CosmosGovModuleAcc, accAddr}), // Mint - this is the only param the manifest module depends on from mint cosmos.NewGenesisKV("app_state.mint.params.blocks_per_year", "6311520"), } @@ -59,6 +57,9 @@ var ( Type: "cosmos", Name: "manifest", ChainID: "manifest-2", + Env: []string{ + fmt.Sprintf("POA_ADMIN_ADDRESS=%s", accAddr), + }, Images: []ibc.DockerImage{ { Repository: "manifest", diff --git a/network/manifest-1/README.md b/network/manifest-1/README.md index 7b3cf96..aeb1a17 100644 --- a/network/manifest-1/README.md +++ b/network/manifest-1/README.md @@ -8,7 +8,7 @@ This guide will assist you in setting up a Manifest-1 network. There are three p ## [Genesis](./GENESIS.md) -This section is tailored for validators intending to participate in the genesis ceremony. Prospective validators must download the genesis file and adhere to the provided steps to join the network. The genesis file originates from the [set-genesis-params.sh](./set-genesis-params.sh) script, which facilitates the generation of a bespoke genesis file. This file allows for the specification of network parameters, such as the Proof of Authority (PoA) token denomination and PoA administrators. +This section is tailored for validators intending to participate in the genesis ceremony. Prospective validators must download the genesis file and adhere to the provided steps to join the network. The genesis file originates from the [set-genesis-params.sh](./set-genesis-params.sh) script, which facilitates the generation of a bespoke genesis file. This file allows for the specification of network parameters, such as the Proof of Authority (PoA) token denomination. ## [Post Genesis](./POST_GENESIS.md) @@ -16,12 +16,11 @@ This section addresses validators aiming to join the network post-initial launch ## Custom Genesis -This section is for those who wish to construct their genesis file for the network, enabling the modification of PoA administrator details and other parameters. Utilizing the [set-genesis-params.sh](./set-genesis-params.sh) script, you can alter the PoA administrator, the PoA denomination, among other settings. +This section is for those who wish to construct their genesis file for the network, enabling the modification of PoA administrator details and other parameters. Utilizing the [set-genesis-params.sh](./set-genesis-params.sh) script, you can alter the PoA denomination, among other settings. -In the script, you will encounter the following lines: +In the script, you will encounter the following line: ```bash -update_genesis '.app_state["poa"]["params"]["admins"]=["manifest1wxjfftrc0emj5f7ldcvtpj05lxtz3t2npghwsf"]' update_genesis '.app_state["staking"]["params"]["bond_denom"]="upoa"' ``` diff --git a/network/manifest-1/genesis.json b/network/manifest-1/genesis.json index a412ecb..d9ad9a7 100644 --- a/network/manifest-1/genesis.json +++ b/network/manifest-1/genesis.json @@ -45,7 +45,7 @@ }, "distribution": { "params": { - "community_tax": "0.020000000000000000", + "community_tax": "0.000000000000000000", "base_proposer_reward": "0.000000000000000000", "bonus_proposer_reward": "0.000000000000000000", "withdraw_addr_enabled": true @@ -189,32 +189,26 @@ }, "mint": { "minter": { - "inflation": "0.130000000000000000", + "inflation": "0.000000000000000000", "annual_provisions": "0.000000000000000000" }, "params": { - "mint_denom": "umfx", - "inflation_rate_change": "0.130000000000000000", - "inflation_max": "0.200000000000000000", - "inflation_min": "0.070000000000000000", + "mint_denom": "notused", + "inflation_rate_change": "0.000000000000000000", + "inflation_max": "0.000000000000000000", + "inflation_min": "0.000000000000000000", "goal_bonded": "0.670000000000000000", "blocks_per_year": "6311520" } }, "params": null, - "poa": { - "params": { - "admins": ["manifest10d07y265gmmuvt4z0w9aw880jnsr700jmq3jzm"], - "allow_validator_self_exit": true - } - }, "slashing": { "params": { "signed_blocks_window": "100", "min_signed_per_window": "0.500000000000000000", "downtime_jail_duration": "600s", - "slash_fraction_double_sign": "0.050000000000000000", - "slash_fraction_downtime": "0.010000000000000000" + "slash_fraction_double_sign": "0.000000000000000000", + "slash_fraction_downtime": "0.000000000000000000" }, "signing_infos": [], "missed_blocks": [] diff --git a/network/manifest-1/set-genesis-params.sh b/network/manifest-1/set-genesis-params.sh index e7d0e68..f98258b 100755 --- a/network/manifest-1/set-genesis-params.sh +++ b/network/manifest-1/set-genesis-params.sh @@ -72,8 +72,6 @@ update_genesis '.app_state["staking"]["params"]["bond_denom"]="upoa"' update_genesis '.app_state["tokenfactory"]["params"]["denom_creation_fee"]=[]' update_genesis '.app_state["tokenfactory"]["params"]["denom_creation_gas_consume"]="250000"' -update_genesis '.app_state["poa"]["params"]["admins"]=["manifest1wxjfftrc0emj5f7ldcvtpj05lxtz3t2npghwsf"]' - # # add genesis accounts # # TODO: # manifestd genesis add-genesis-account manifest1hj5fveer5cjtn4wd6wstzugjfdxzl0xp8ws9ct 1umfx --append \ No newline at end of file diff --git a/scripts/test_node.sh b/scripts/test_node.sh index c7ad176..605d766 100644 --- a/scripts/test_node.sh +++ b/scripts/test_node.sh @@ -3,7 +3,7 @@ # # Example: # POA_ADMIN_ADDRESS=manifest1hj5fveer5cjtn4wd6wstzugjfdxzl0xp8ws9ct CHAIN_ID="local-1" HOME_DIR="~/.manifest" TIMEOUT_COMMIT="500ms" CLEAN=true sh scripts/test_node.sh -# CHAIN_ID="local-2" HOME_DIR="~/.manifest2" CLEAN=true RPC=36657 REST=2317 PROFF=6061 P2P=36656 GRPC=8090 GRPC_WEB=8091 ROSETTA=8081 TIMEOUT_COMMIT="500ms" sh scripts/test_node.sh +# POA_ADMIN_ADDRESS=manifest1hj5fveer5cjtn4wd6wstzugjfdxzl0xp8ws9ct CHAIN_ID="local-2" HOME_DIR="~/.manifest2" CLEAN=true RPC=36657 REST=2317 PROFF=6061 P2P=36656 GRPC=8090 GRPC_WEB=8091 ROSETTA=8081 TIMEOUT_COMMIT="500ms" sh scripts/test_node.sh # # To use unoptomized wasm files up to ~5mb, add: MAX_WASM_SIZE=5000000 @@ -81,9 +81,6 @@ from_scratch () { # Custom Modules - # POA - update_test_genesis '.app_state["poa"]["params"]["admins"]=["'$POA_ADMIN_ADDRESS'"]' - # TokenFactory update_test_genesis '.app_state["tokenfactory"]["params"]["denom_creation_fee"]=[]' update_test_genesis '.app_state["tokenfactory"]["params"]["denom_creation_gas_consume"]=2000000'