Skip to content

Commit

Permalink
Fix: deprecates the flags --whitelisters and --nonwhitelisters fr…
Browse files Browse the repository at this point in the history
…om the governance:show command (#425)

### Description

Deprecates the flags `--whitelisters` and `--nonwhitelisters` from the
governance:show command

### Related issues

- Fixes #414
  • Loading branch information
nicolasbrugneaux authored Nov 14, 2024
1 parent 79cbdf0 commit 952bc81
Show file tree
Hide file tree
Showing 3 changed files with 51 additions and 21 deletions.
5 changes: 5 additions & 0 deletions .changeset/good-peas-type.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@celo/celocli': patch
---

deprecates the flags --whitelisters and --nonwhitelisters from the governance:show command
54 changes: 36 additions & 18 deletions docs/command-line-interface/governance.md
Original file line number Diff line number Diff line change
Expand Up @@ -437,16 +437,19 @@ FLAGS
provided file
--nonwhitelisters If set, displays validators
that have not whitelisted
the hotfix.
the hotfix.(will be removed
when L2 launches
--notwhitelisted List validators who have not
whitelisted the specified
hotfix
hotfix (will be removed when
L2 launches
--proposalID=<value> UUID of proposal to view
--raw Display proposal in raw
bytes format
--whitelisters If set, displays validators
that have whitelisted the
hotfix.
hotfix.(will be removed when
L2 launches
DESCRIPTION
Show information about a governance proposal, hotfix, or account.
Expand Down Expand Up @@ -507,16 +510,19 @@ FLAGS
provided file
--nonwhitelisters If set, displays validators
that have not whitelisted
the hotfix.
the hotfix.(will be removed
when L2 launches
--notwhitelisted List validators who have not
whitelisted the specified
hotfix
hotfix (will be removed when
L2 launches
--proposalID=<value> UUID of proposal to view
--raw Display proposal in raw
bytes format
--whitelisters If set, displays validators
that have whitelisted the
hotfix.
hotfix.(will be removed when
L2 launches
DESCRIPTION
Show information about a governance proposal, hotfix, or account.
Expand Down Expand Up @@ -575,16 +581,19 @@ FLAGS
provided file
--nonwhitelisters If set, displays validators
that have not whitelisted
the hotfix.
the hotfix.(will be removed
when L2 launches
--notwhitelisted List validators who have not
whitelisted the specified
hotfix
hotfix (will be removed when
L2 launches
--proposalID=<value> UUID of proposal to view
--raw Display proposal in raw
bytes format
--whitelisters If set, displays validators
that have whitelisted the
hotfix.
hotfix.(will be removed when
L2 launches
DESCRIPTION
Show information about a governance proposal, hotfix, or account.
Expand Down Expand Up @@ -674,16 +683,19 @@ FLAGS
provided file
--nonwhitelisters If set, displays validators
that have not whitelisted
the hotfix.
the hotfix.(will be removed
when L2 launches
--notwhitelisted List validators who have not
whitelisted the specified
hotfix
hotfix (will be removed when
L2 launches
--proposalID=<value> UUID of proposal to view
--raw Display proposal in raw
bytes format
--whitelisters If set, displays validators
that have whitelisted the
hotfix.
hotfix.(will be removed when
L2 launches
DESCRIPTION
Show information about a governance proposal, hotfix, or account.
Expand Down Expand Up @@ -742,16 +754,19 @@ FLAGS
provided file
--nonwhitelisters If set, displays validators
that have not whitelisted
the hotfix.
the hotfix.(will be removed
when L2 launches
--notwhitelisted List validators who have not
whitelisted the specified
hotfix
hotfix (will be removed when
L2 launches
--proposalID=<value> UUID of proposal to view
--raw Display proposal in raw
bytes format
--whitelisters If set, displays validators
that have whitelisted the
hotfix.
hotfix.(will be removed when
L2 launches
DESCRIPTION
Show information about a governance proposal, hotfix, or account.
Expand Down Expand Up @@ -810,16 +825,19 @@ FLAGS
provided file
--nonwhitelisters If set, displays validators
that have not whitelisted
the hotfix.
the hotfix.(will be removed
when L2 launches
--notwhitelisted List validators who have not
whitelisted the specified
hotfix
hotfix (will be removed when
L2 launches
--proposalID=<value> UUID of proposal to view
--raw Display proposal in raw
bytes format
--whitelisters If set, displays validators
that have whitelisted the
hotfix.
hotfix.(will be removed when
L2 launches
DESCRIPTION
Show information about a governance proposal, hotfix, or account.
Expand Down
13 changes: 10 additions & 3 deletions packages/cli/src/commands/governance/show.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,14 +44,20 @@ export default class Show extends BaseCommand {
description: 'Hash of hotfix proposal',
}),
notwhitelisted: Flags.boolean({
description: 'List validators who have not whitelisted the specified hotfix',
description:
'List validators who have not whitelisted the specified hotfix (will be removed when L2 launches',
deprecated: true,
}),
whitelisters: Flags.boolean({
description: 'If set, displays validators that have whitelisted the hotfix.',
description:
'If set, displays validators that have whitelisted the hotfix.(will be removed when L2 launches',
deprecated: true,
exclusive: ['nonwhitelisters', 'account', 'proposalID'],
}),
nonwhitelisters: Flags.boolean({
description: 'If set, displays validators that have not whitelisted the hotfix.',
description:
'If set, displays validators that have not whitelisted the hotfix.(will be removed when L2 launches',
deprecated: true,
exclusive: ['whitelisters', 'account', 'proposalID'],
}),
afterExecutingProposal: Flags.string({
Expand Down Expand Up @@ -150,6 +156,7 @@ export default class Show extends BaseCommand {
return
}

// TODO: remove this bit when L2 launches
const passing = await governance.isHotfixPassing(hotfixBuf)
printValueMap({ passing })
const tally = await governance.hotfixWhitelistValidatorTally(hotfixBuf)
Expand Down

0 comments on commit 952bc81

Please sign in to comment.