From 50b45504c7215bb364805409e0737c5059297af9 Mon Sep 17 00:00:00 2001 From: Julian Toledano Date: Thu, 23 Jan 2025 10:09:35 +0100 Subject: [PATCH] changelog + rabbit --- CHANGELOG.md | 4 ++++ tests/systemtests/construction_test.go | 2 +- tests/systemtests/rest_client.go | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 83d2e1b..3bd992d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -45,6 +45,10 @@ Ref: https://keepachangelog.com/en/1.0.0/ * [180](https://github.com/cosmos/rosetta/pull/180) Update to cosmos-sdk v0.52.0-rc.1. * [180](https://github.com/cosmos/rosetta/pull/180) Added bech32 prefix flag. +### Bug Fixes + +* [#190](https://github.com/cosmos/rosetta/pull/190) Fixed construction payloads to properly handle transaction signers. + ## [v0.50.11](https://github.com/cosmos/rosetta/releases/tag/v0.50.11) 2024-12-19 ### Improvements diff --git a/tests/systemtests/construction_test.go b/tests/systemtests/construction_test.go index b4af026..04832e6 100644 --- a/tests/systemtests/construction_test.go +++ b/tests/systemtests/construction_test.go @@ -103,7 +103,7 @@ func TestPayloads(t *testing.T) { op := operation{ msgType: "/cosmos.bank.v1beta1.MsgSend", - metadata: fmt.Sprintf(`{"from_address": "%s", "to_address": "%s", "amount":[{"amount":"123", "denom":"stake"}]}`, addr, "cosmos1qcym25uch54xmja4eys35zcyr8npwlm80glwuk"), + metadata: fmt.Sprintf(`{"from_address": "%s", "to_address": "%s", "amount":[{"amount":"123", "denom":"stake"}]}`, addr, cli.AddKey("to_address")), } res, err := rosettaRest.constructionPayloads(`"signer_data":[{"account_number":1, "sequence": 0}]`, hexPk, op) assert.NoError(t, err) diff --git a/tests/systemtests/rest_client.go b/tests/systemtests/rest_client.go index 14c5c14..ccd809d 100644 --- a/tests/systemtests/rest_client.go +++ b/tests/systemtests/rest_client.go @@ -183,7 +183,7 @@ func (o *operation) String() string { func payloadsOperations(ops ...operation) []string { r := make([]string, len(ops)) for i, op := range ops { - r = append(r, fmt.Sprintf(`{"operation_identifier":{"index": %d}, %s}`, i, op.String())) + r[i] = fmt.Sprintf(`{"operation_identifier":{"index": %d}, %s}`, i, op.String()) } return r