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

Limited Delegation txs #2

Closed
Sayeh-1337 opened this issue Nov 23, 2020 · 6 comments
Closed

Limited Delegation txs #2

Sayeh-1337 opened this issue Nov 23, 2020 · 6 comments

Comments

@Sayeh-1337
Copy link
Contributor

@kwunyeung , @RiccardoM , @bragaz

The network is restricted to 12 txs

@kwunyeung
Copy link

The networks should not have this restriction and we can also see hundreds of txs are being committed. This is the current consensus parameters.

"consensus_params": {
    "block": {
      "max_bytes": "22020096",
      "max_gas": "-1",
      "time_iota_ms": "1000"
    },
    "evidence": {
      "max_age_duration": "172800000000000",
      "max_age_num_blocks": "100000"
    },
    "validator": {
      "pub_key_types": [
        "ed25519"
      ]
    }
  },

max_gas is set to -1 which is no max gas limit. The spam is requesting 999,999,999 gas.

image

I think the tx should be able to put all the messages and broadcast without problem. @Sayeh-1337 how about you make the signed tx and send me to take a look?

@Sayeh-1337
Copy link
Contributor Author

@kwunyeung
this is stdMsg = { json: { account_number: '51088', chain_id: 'morpheus-10000', fee: { amount: [Array], gas: '200000' }, memo: 'Desmos Xenia Blessing !!', msgs: [ [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object] ], sequence: '38' }, bytes: [ 123, 34, 97, 99, 99, 111, 117, 110, 116, 95, 110, 117, 109, 98, 101, 114, 34, 58, 34, 53, 49, 48, 56, 56, 34, 44, 34, 99, 104, 97, 105, 110, 95, 105, 100, 34, 58, 34, 109, 111, 114, 112, 104, 101, 117, 115, 45, 49, 48, 48, 48, 48, 34, 44, 34, 102, 101, 101, 34, 58, 123, 34, 97, 109, 111, 117, 110, 116, 34, 58, 91, 123, 34, 97, 109, 111, 117, 110, 116, 34, 58, 34, 49, 48, 48, 48, 48, 34, 44, 34, 100, 101, 110, 111, 109, 34, 58, 34, 117, 100, ... 15587 more items ] }

Object = { type : "cosmos-sdk/MsgDelegate", value : { amount: { amount: String(amount), denom: denom }, delegator_address: *Address*, validator_address: *desmosvaloper...." } }

This is the Signed Msg = { tx: { msg: [ [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object], [Object] ], fee: { amount: [Array], gas: '200000' }, signatures: [ [Object] ], memo: 'Desmos Xenia Blessing !!' }, mode: 'sync' }

This signed Msg not processed by the network

@RiccardoM
Copy link

@Sayeh-1337 This is probably due to the fact that you're trying to execute more than 60 messages requiring that only a max of 200,000 gas is used. What is suggest you to do is specify the gas amount based on the messages number:

gas = msgs.length * 200_000

@kwunyeung
Copy link

@Sayeh-1337 please set the gas to a larger value like how the spam did 😅

@Sayeh-1337
Copy link
Contributor Author

@RiccardoM Thank you, worked like a charm 😃. also, it worked when I calculated the typical fees fees = gas * gas-prices

@kwunyeung I do it as the spam did it but with a higher fee than it 😁. this raises a question for me how the spam does it with a lower fee.

@kwunyeung
Copy link

They either

  1. Set the gas-prices to 0.000026udaric, the fees will be 0.000026 * 1,000,000,000 = 26000udaric. Or,
  2. Don't set gas-prices and set fees directly 26000udaric. This tx can then be broadcasted to any nodes with min-gas-prices set to "".

Probably the 2nd option.

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

No branches or pull requests

3 participants