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

Unable to send tx from multisig address #59

Closed
4 tasks
cbarraford opened this issue Jun 27, 2019 · 7 comments
Closed
4 tasks

Unable to send tx from multisig address #59

cbarraford opened this issue Jun 27, 2019 · 7 comments
Labels
scope: docs Improvements or additions to documentation

Comments

@cbarraford
Copy link

Summary of Bug

I'm following along with the instructions given here, to create multisig address and transaction.

While trying to create the transaction to send coinage...

$ gaiacli tx send p1p2p3 cosmos1570v2fq3twt0f0x02vhxpuzc9jc4yl30q2qned 1000000uatom
  ERROR: {"codespace":"sdk","code":9,"message":"account cosmos173a2ffcr6t4t33espwrhv292wfkmmsmf8pnxmv does not exist"}
$ gaiacli keys show p1p2p3
- name: p1p2p3
  type: multi
  address: cosmos173a2ffcr6t4t33espwrhv292wfkmmsmf8pnxmv
  pubkey: cosmospub1ytql0csgqgfzd666axrjzqks4r04s85ef4zccrum3w4nd6w4wnfpzspjhekrpa7dlppe3s5vk5fzd666axrjzqs75n22x3vfpxslfs5us84rnm8tjpyzjgq82xxtfjxux52g39cregfzd666axrjzqe47t0gcuj4k96xjdw954k7zmn46nu0mwtnl5sa7qdmh6hv3k98tqpjmel0
  mnemonic: ""
  threshold: 2
  pubkeys:
  - address: cosmos1x27g4a5vumdf7eytk240zqrhegqd0h8sjfj5ma
    pubkey: cosmospub1addwnpepqtg23h6cr6v563vvp7dch2eka82hf5s3gqetumps7lxlssucc2xt24gtkad
    weight: 1
  - address: cosmos10k29n523hpqchg6nyxfgxha6qqtvuzmzv6unzk
    pubkey: cosmospub1addwnpepqg02f49rgkysng05c2wgr63ean4eqjpfyqr4rr95erwr29ygjupu5l7g03u
    weight: 1
  - address: cosmos1kquv4jlsykjxm9ujuyp0qpwlalpdq6ycdhke2p
    pubkey: cosmospub1addwnpepqv6l9h5vwf2mzarfxhz62m0pde6af78ah9el6gwlqxamatkgmzn4spj3r3l
    weight: 1

Version

0.0.0-34-g0432ac5

Steps to Reproduce

Follow along with multisig documentation


For Admin Use

  • Not duplicate issue
  • Appropriate labels applied
  • Appropriate contributors tagged
  • Contributor assigned/self-assigned
@alexanderbez
Copy link
Contributor

@cbarraford are you running this command on mainnet or on a local net? It looks like you've succesfully created a proper multisig address. Even so, you cannot actually send from this account as it does not exist in state -- it has to be sent funds first.

@cbarraford
Copy link
Author

@alexanderbez local net. I hadn't realized that funds needed to exist in the multisig address first. That would be a surprising error then. Ie, "account doesn't exist" vs "no funds available in account". Thanks for the help.

@cbarraford
Copy link
Author

also, the documentation I was following didn't mention about sending coins to the multisig address. Maybe a doc update would be helpful here. 🤷‍♂

@cbarraford
Copy link
Author

Continuing with another issue with the same documentation...

gaiacli tx multisign /tmp/unsigned.json p1p2p3 /tmp/p1signature.json /tmp/p2signature.json
ERROR: couldn't verify signature

OR

gaiacli tx multisign /tmp/unsigned.json p1p2p3 /tmp/p1signature.json /tmp/p2signature.json --chain-id testing
ERROR: provided key EB5AE98721024233FB2E350C6E810E5C47B3D99581C7317EC590D409F30ECA3D4320A684B021 doesn't exist in pubkeys:
EB5AE9872102D0A8DF581E994D458C0F9B8BAB36E9D574D2114032BE6C30F7CDF84398C28CB5
EB5AE98721021EA4D4A3458909A1F4C29C81EA39ECEB9048292007518CB4C8DC3514889703CA
EB5AE987210335F2DE8C7255B1746935C5A56DE16E75D4F8FDB973FD21DF01BBBEAEC8D8A758

Here are the relavant files...

unsigned.json

{
  "type": "auth/StdTx",
  "value": {
    "msg": [
      {
        "type": "cosmos-sdk/MsgSend",
        "value": {
          "from_address": "cosmos173a2ffcr6t4t33espwrhv292wfkmmsmf8pnxmv",
          "to_address": "cosmos1570v2fq3twt0f0x02vhxpuzc9jc4yl30q2qned",
          "amount": [
            {
              "denom": "stake",
              "amount": "1"
            }
          ]
        }
      }
    ],
    "fee": {
      "amount": [],
      "gas": "200000"
    },
    "signatures": null,
    "memo": ""
  }
}

p1signature.json

{
  "pub_key": {
    "type": "tendermint/PubKeySecp256k1",
    "value": "AkIz+y41DG6BDlxHs9mVgccxfsWQ1AnzDso9QyCmhLAh"
  },
  "signature": "HRfZIXiMV2eypRmpw6GCTChhR78bljGJaLdaAV4huuksAVgJb+WK2g3qXguSxMNCtEa81nx7Um0zfihDo6j9DQ=="
}

p2signature.json

{
  "pub_key": {
    "type": "tendermint/PubKeySecp256k1",
    "value": "AzXy3oxyVbF0aTXFpW3hbnXU+P25c/0h3wG7vq7I2KdY"
  },
  "signature": "ubn4SEi5D8BCGygiR49dwV+1hWPF2cCIzurW/A7iYeZY6CnmwVPD6Jx+aYXe5Mf2uqrfLqwHrV+jHqRZx+59sw=="
}

@alexanderbez
Copy link
Contributor

I'll update the documentation to state that the multisig address/account must exist in state prior to using it.

With regards to doesn't exist in pubkeys error, that is user error. It shows you the pubkey that doesn't belong in the set of pubkeys. You have 2-of-3 mutlisig, you provided 2 keys. EB5AE98721024233FB2E350C6E810E5C47B3D99581C7317EC590D409F30ECA3D4320A684B021 is not part of the 3.

@cbarraford
Copy link
Author

@alexanderbez thanks for that. Got it sorted. Feel free to close this issue, or leave it open for updating the documentation like you said. Much appreciated 👍

@tac0turtle tac0turtle added the scope: docs Improvements or additions to documentation label Apr 23, 2020
@nooomski
Copy link
Contributor

Closing this as this repo doesn't contain this doc anymore and the SDK only covers this briefly. With groups coming out in Q1/Q2, I don't see this as a documentation priority right now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
scope: docs Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

4 participants