Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

InterchainTest for v3 #243

Closed
wants to merge 6 commits into from
Closed

InterchainTest for v3 #243

wants to merge 6 commits into from

Conversation

anhductn2001
Copy link
Contributor

Description and Motivation

Add InterchainTest (Start_chain, ibc_transfer, Upgrade_chain,...) for testing easy

  • I have read Migaloo's contribution guidelines.
  • My pull request has a sound title and description (not something vague like Update index.md)
  • All existing and new tests are passing.
  • I updated/added relevant documentation.
  • The code is formatted properly golangci-lint run ./... --fix.

Copy link
Collaborator

@faddat faddat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we stop using the path tests/interchaintest and instead just use interchaintest?

(since there's nothing else under tests/)

@anhductn2001
Copy link
Contributor Author

Yes, I am going to change it. @faddat

@anhductn2001
Copy link
Contributor Author

I am writing upgrade_chain_test for it!

@anhductn2001
Copy link
Contributor Author

anhductn2001 commented Oct 2, 2023

I'm really stuck at the submitLegacyUpgradeProposal step. The Err Log:

error in json rpc client, with http response metadata: (Status: 200 OK, Protocol HTTP/1.1). error unmarshalling result: illegal base64 data at input byte 0

@anhductn2001
Copy link
Contributor Author

I logged deeper into cometbft and printed out the json that could not be unmarshalled:

decodeReflectStruct
{
  "hash": "50B07D4C89E2406AD876D067D2E1913566ABC0E42F1E943547E71935DBF18CD9",
  "height": "9",
  "index": 0,
  "tx_result": {
    "code": 0,
    "data": "EjMKLS9jb3Ntb3MuZ292LnYxYmV0YTEuTXNnU3VibWl0UHJvcG9zYWxSZXNwb25zZRICCAE=",
    "log": "[{\"msg_index\":0,\"events\":[{\"type\":\"message\",\"attributes\":[{\"key\":\"action\",\"value\":\"/cosmos.gov.v1beta1.MsgSubmitProposal\"},{\"key\":\"sender\",\"value\":\"migaloo14cugmx9zxvwl4r8ltu22g5uauku9e7p9wc45dw\"},{\"key\":\"module\",\"value\":\"gov\"}]},{\"type\":\"submit_proposal\",\"attributes\":[{\"key\":\"proposal_id\",\"value\":\"1\"},{\"key\":\"proposal_messages\",\"value\":\",/cosmos.gov.v1.MsgExecLegacyContent\"}]},{\"type\":\"coin_spent\",\"attributes\":[{\"key\":\"spender\",\"value\":\"migaloo14cugmx9zxvwl4r8ltu22g5uauku9e7p9wc45dw\"},{\"key\":\"amount\",\"value\":\"500000uwhale\"}]},{\"type\":\"coin_received\",\"attributes\":[{\"key\":\"receiver\",\"value\":\"migaloo10d07y265gmmuvt4z0w9aw880jnsr700jhk6lra\"},{\"key\":\"amount\",\"value\":\"500000uwhale\"}]},{\"type\":\"transfer\",\"attributes\":[{\"key\":\"recipient\",\"value\":\"migaloo10d07y265gmmuvt4z0w9aw880jnsr700jhk6lra\"},{\"key\":\"sender\",\"value\":\"migaloo14cugmx9zxvwl4r8ltu22g5uauku9e7p9wc45dw\"},{\"key\":\"amount\",\"value\":\"500000uwhale\"}]},{\"type\":\"message\",\"attributes\":[{\"key\":\"sender\",\"value\":\"migaloo14cugmx9zxvwl4r8ltu22g5uauku9e7p9wc45dw\"}]},{\"type\":\"proposal_deposit\",\"attributes\":[{\"key\":\"amount\",\"value\":\"500000uwhale\"},{\"key\":\"proposal_id\",\"value\":\"1\"}]}]}]",
    "info": "",
    "gas_wanted": "172057",
    "gas_used": "134346",
    "events": [
      {
        "type": "tx",
        "attributes": [
          {
            "key": "fee",
            "value": "",
            "index": true
          },
          {
            "key": "fee_payer",
            "value": "migaloo14cugmx9zxvwl4r8ltu22g5uauku9e7p9wc45dw",
            "index": true
          }
        ]
      },
      {
        "type": "tx",
        "attributes": [
          {
            "key": "acc_seq",
            "value": "migaloo14cugmx9zxvwl4r8ltu22g5uauku9e7p9wc45dw/0",
            "index": true
          }
        ]
      },
      {
        "type": "tx",
        "attributes": [
          {
            "key": "signature",
            "value": "ywATF4Tc+VbUBWq4eM8TfhvfHmF04PuzGlMO/n+t67Ni5mFgshrnZlaWkJ3shV8pqzM9LIwssqNDrh+Pa3p1sA==",
            "index": true
          }
        ]
      },
      {
        "type": "message",
        "attributes": [
          {
            "key": "action",
            "value": "/cosmos.gov.v1beta1.MsgSubmitProposal",
            "index": true
          },
          {
            "key": "sender",
            "value": "migaloo14cugmx9zxvwl4r8ltu22g5uauku9e7p9wc45dw",
            "index": true
          },
          {
            "key": "module",
            "value": "gov",
            "index": true
          }
        ]
      },
      {
        "type": "submit_proposal",
        "attributes": [
          {
            "key": "proposal_id",
            "value": "1",
            "index": true
          },
          {
            "key": "proposal_messages",
            "value": ",/cosmos.gov.v1.MsgExecLegacyContent",
            "index": true
          }
        ]
      },
      {
        "type": "coin_spent",
        "attributes": [
          {
            "key": "spender",
            "value": "migaloo14cugmx9zxvwl4r8ltu22g5uauku9e7p9wc45dw",
            "index": true
          },
          {
            "key": "amount",
            "value": "500000uwhale",
            "index": true
          }
        ]
      },
      {
        "type": "coin_received",
        "attributes": [
          {
            "key": "receiver",
            "value": "migaloo10d07y265gmmuvt4z0w9aw880jnsr700jhk6lra",
            "index": true
          },
          {
            "key": "amount",
            "value": "500000uwhale",
            "index": true
          }
        ]
      },
      {
        "type": "transfer",
        "attributes": [
          {
            "key": "recipient",
            "value": "migaloo10d07y265gmmuvt4z0w9aw880jnsr700jhk6lra",
            "index": true
          },
          {
            "key": "sender",
            "value": "migaloo14cugmx9zxvwl4r8ltu22g5uauku9e7p9wc45dw",
            "index": true
          },
          {
            "key": "amount",
            "value": "500000uwhale",
            "index": true
          }
        ]
      },
      {
        "type": "message",
        "attributes": [
          {
            "key": "sender",
            "value": "migaloo14cugmx9zxvwl4r8ltu22g5uauku9e7p9wc45dw",
            "index": true
          }
        ]
      },
      {
        "type": "proposal_deposit",
        "attributes": [
          {
            "key": "amount",
            "value": "500000uwhale",
            "index": true
          },
          {
            "key": "proposal_id",
            "value": "1",
            "index": true
          }
        ]
      }
    ],
    "codespace": ""
  },
  "tx": "CtIBCs8BCiUvY29zbW9zLmdvdi52MWJldGExLk1zZ1N1Ym1pdFByb3Bvc2FsEqUBCmEKLy9jb3Ntb3MudXBncmFkZS52MWJldGExLlNvZnR3YXJlVXBncmFkZVByb3Bvc2FsEi4KB1VwZ3JhZGUSBUZpcnN0GhwKAnYzEgsIgJK4w5j+////ARgcIgdVUEdSQURFEhAKBnV3aGFsZRIGNTAwMDAwGi5taWdhbG9vMTRjdWdteDl6eHZ3bDRyOGx0dTIyZzV1YXVrdTllN3A5d2M0NWR3ElYKTgpGCh8vY29zbW9zLmNyeXB0by5zZWNwMjU2azEuUHViS2V5EiMKIQO1ymuGpe0CmwMzWsl8kLQeDtdHDSwlFBBea5Gh1MWuFRIECgIIARIEEJnAChpAywATF4Tc+VbUBWq4eM8TfhvfHmF04PuzGlMO/n+t67Ni5mFgshrnZlaWkJ3shV8pqzM9LIwssqNDrh+Pa3p1sA==",
  "proof": {
    "root_hash": "44AAB3F72C70934C84E8F4589F196B8F5AC66288EEAA53A80848C82E33C95645",
    "data": "CtIBCs8BCiUvY29zbW9zLmdvdi52MWJldGExLk1zZ1N1Ym1pdFByb3Bvc2FsEqUBCmEKLy9jb3Ntb3MudXBncmFkZS52MWJldGExLlNvZnR3YXJlVXBncmFkZVByb3Bvc2FsEi4KB1VwZ3JhZGUSBUZpcnN0GhwKAnYzEgsIgJK4w5j+////ARgcIgdVUEdSQURFEhAKBnV3aGFsZRIGNTAwMDAwGi5taWdhbG9vMTRjdWdteDl6eHZ3bDRyOGx0dTIyZzV1YXVrdTllN3A5d2M0NWR3ElYKTgpGCh8vY29zbW9zLmNyeXB0by5zZWNwMjU2azEuUHViS2V5EiMKIQO1ymuGpe0CmwMzWsl8kLQeDtdHDSwlFBBea5Gh1MWuFRIECgIIARIEEJnAChpAywATF4Tc+VbUBWq4eM8TfhvfHmF04PuzGlMO/n+t67Ni5mFgshrnZlaWkJ3shV8pqzM9LIwssqNDrh+Pa3p1sA==",
    "proof": {
      "total": "1",
      "index": "0",
      "leaf_hash": "RKqz9yxwk0yE6PRYnxlrj1rGYojuqlOoCEjILjPJVkU=",
      "aunts": []
    }
  }
}
decodeStdlib
9
decodeStdlib
0
error in json rpc client, with http response metadata: (Status: 200 OK, Protocol HTTP/1.1). error unmarshalling result: illegal base64 data at input byte 0

@anhductn2001
Copy link
Contributor Author

anhductn2001 commented Oct 2, 2023

Something wrong with value "index" : 0 ?

@anhductn2001
Copy link
Contributor Author

cc: @faddat

@anhductn2001 anhductn2001 requested a review from faddat October 10, 2023 03:14
@faddat faddat closed this Jun 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants