> For the complete documentation index, see [llms.txt](https://docs.gnoswap.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.gnoswap.io/contracts/errors/governance.md).

# Governance

The following table outlines potential errors that may occur during interactions with the governance contract in GnoSwap:

## Governance

| Code                   | Message                                 |
| ---------------------- | --------------------------------------- |
| GNOSWAP-GOVERNANCE-001 | invalid input                           |
| GNOSWAP-GOVERNANCE-002 | requested data not found                |
| GNOSWAP-GOVERNANCE-003 | not enough balance                      |
| GNOSWAP-GOVERNANCE-004 | cannot vote twice                       |
| GNOSWAP-GOVERNANCE-005 | not enough voting power                 |
| GNOSWAP-GOVERNANCE-006 | cannot cancel already canceled proposal |
| GNOSWAP-GOVERNANCE-007 | unable to cancel voting proposal        |
| GNOSWAP-GOVERNANCE-008 | cannot execute text proposal            |
| GNOSWAP-GOVERNANCE-009 | unable to vote out of voting period     |
| GNOSWAP-GOVERNANCE-010 | invalid message format                  |
| GNOSWAP-GOVERNANCE-011 | already active proposal                 |
| GNOSWAP-GOVERNANCE-012 | proposal not found                      |
| GNOSWAP-GOVERNANCE-013 | proposal not executable                 |
| GNOSWAP-GOVERNANCE-014 | not proposer                            |
| GNOSWAP-GOVERNANCE-015 | invalid configuration                   |
| GNOSWAP-GOVERNANCE-016 | invalid execution: handler not found    |
| GNOSWAP-GOVERNANCE-017 | invalid smoothing period                |
| GNOSWAP-GOVERNANCE-018 | active proposal index requires pruning  |

## Governance Staker

| Code                    | Message                                         |
| ----------------------- | ----------------------------------------------- |
| GNOSWAP-GOV\_STAKER-001 | requested data not found                        |
| GNOSWAP-GOV\_STAKER-002 | invalid amount                                  |
| GNOSWAP-GOV\_STAKER-003 | zero delegated amount                           |
| GNOSWAP-GOV\_STAKER-004 | not enough delegated                            |
| GNOSWAP-GOV\_STAKER-005 | invalid address                                 |
| GNOSWAP-GOV\_STAKER-006 | not enough balance                              |
| GNOSWAP-GOV\_STAKER-007 | cannot delegate less than minimum amount        |
| GNOSWAP-GOV\_STAKER-008 | invalid snapshot time                           |
| GNOSWAP-GOV\_STAKER-009 | cannot redelegate to same address               |
| GNOSWAP-GOV\_STAKER-010 | withdraw is not collectable                     |
| GNOSWAP-GOV\_STAKER-011 | amount must be non-negative                     |
| GNOSWAP-GOV\_STAKER-012 | total staked amount would overflow              |
| GNOSWAP-GOV\_STAKER-013 | remove amount exceeds total staked amount       |
| GNOSWAP-GOV\_STAKER-014 | remove amount exceeds staked amount             |
| GNOSWAP-GOV\_STAKER-015 | amount must be positive                         |
| GNOSWAP-GOV\_STAKER-016 | must update reward debt before claiming rewards |
| GNOSWAP-GOV\_STAKER-017 | delegated amount cannot be negative             |
| GNOSWAP-GOV\_STAKER-018 | undelegation amount cannot be negative          |
| GNOSWAP-GOV\_STAKER-019 | delegation not found                            |
| GNOSWAP-GOV\_STAKER-020 | accrual epoch is older than the epoch in force  |
| GNOSWAP-GOV\_STAKER-021 | invalid accrual buckets                         |
