What is the data type of the commission of a validator?

What is the data type of the commission of a validator?

  • Integers?
  • Floating-points?

In the dashboard(https://raw.githubusercontent.com/gluwa/creditcoin-docs/main/.gitbook/assets/image%20(4).png), validators can set the reward commission as Integers type only.

But It looks like that creditcoin-cli permits both Integer and Floating type commission.

If the commission type is limited to Integer type,

How about fixing the code(creditcoin/scripts/cc-cli/src/utils/perbill.ts at 865566153ce0d0037039ca25362984bf00d114df ยท gluwa/creditcoin ยท GitHub) like this

return Math.floor(value * 10_000_000);
โ†’
return Math.floor(value) * 10_000_000;

2 Likes

Thank you. The feedback has been passed on to the dev team.

2 Likes