Decodes and displays Namada governance proposals in a human-readable format.
-
Clone the repository:
git clone https://github.com/andreidavid/namada-tools.git cd namada-tools -
Install dependencies:
pip install -r requirements.txt
-
Create a
.envfile with your RPC endpoint:echo 'RPC_URL="http://x.y.z"' > .env
Query a proposal by ID:
python proposal_decoder.py --proposal-id <ID>Example output:
Last committed epoch: 15
Proposal Id: 0
Type: Default with Wasm
Author: tnam1qqgll8x8rz9fvtdv8q6n985za0vjvgyu0udxh7fp
Content: {"abstract": "Initialize phase 2...", "discussions-to": "https://forum.namada.net/...", "title": "Phase 1 -> 2"}
Start Epoch: 1
End Epoch: 13
Activation Epoch: 14
Status: ended
Data Hash: EAF15308CEC6A657EE42FC599259A3F8A7D629991EEF1E0917653C36176CA5FCOptions:
-i, --proposal-id: Proposal ID to query (default: 0)-h, --help: Show help message
- Python 3.7+
- Required Python packages:
- borsh-construct
- python-dotenv
- requests