voteagora / agora-next

The Onchain Governance App
https://agora.xyz
MIT License
49 stars 16 forks source link

I can't store the budget allocations #566

Closed vidvidvid closed 1 month ago

vidvidvid commented 1 month ago

http://localhost:3000/api/agora/retrofunding/rounds/6/ballots/0x92084Bed8635d82DB600E100539A61a6d4209403/categories

payload: {
    "category_slug": "GOV_INFRA",
    "allocation": 34.33,
    "locked": true
}

500 Internal Server Error

response:
Internal server error: PrismaClientKnownRequestError: 
Invalid `prisma.categoryAllocations.upsert()` invocation:
Foreign key constraint failed on the field: `category_allocations_category_slug_round_fkey (index)
linear[bot] commented 1 month ago

AGORA-3085 I can't store the budget allocations

stepandel commented 1 month ago

@vidvidvid you are using non-existent category slug. List of slugs: https://github.com/voteagora/agora-next/blob/main/spec/oas_v1.yaml#L1317

vidvidvid commented 1 month ago

ahh ye, right. works now! :)