Commit 5b421c0
committed
fix: snapshot box proposal rendering
The Box API uses different request formats than snapshot.org hub.
Key differences:
1. Proposal query expects combined ID: "space/proposal" (e.g., "0x07bd.../54")
2. Space query uses separate parameters: indexer="sn" and id=space_address
3. Votes query expects string proposal ID and space identifier with prefix
Implementation:
- Parse space identifier to extract indexer ("sn") and space address
- Fetch space data using correct indexer/id parameters
- Fetch proposal data using combined ID format
- Map voting_power_validation_strategies_parsed_metadata from Space API
- Preserve original space identifier for votes query
- Add proper network, state, and default values for missing fields
Fixes MF-67741 parent a91a7cf commit 5b421c0
2 files changed
+197
-125
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| |||
82 | 82 | | |
83 | 83 | | |
84 | 84 | | |
85 | | - | |
86 | | - | |
| 85 | + | |
87 | 86 | | |
88 | 87 | | |
89 | 88 | | |
| |||
0 commit comments