Fix broken debate links and navigation gaps in the SciDEX debate system. Two API endpoints generate links to /debate/{id} (singular) instead of /debates/{id} (plural), causing 404s for any debate link from the timeline or event feed. Additionally, "Debates" is missing from the top-bar dropdown navigation, making the debates page undiscoverable without opening the hamburger sidebar.
/debate/{id} → /debates/{id} in timeline API (api.py line ~4036)/debate/{id} → /debates/{id} in event feed API (api.py line ~44386)/debates route returns 200/debate/ (singular) is not referenced anywhere in the codebase/debate/ (singular) references in api.py/debates/ (plural) which is the actual registered route/debate/ references remain/debates (listing) and /debates/{session_id} (detail) exist and work correctly/debate/{id} (singular) instead of /debates/{id} (plural)/debate/ → /debates/Verified all acceptance criteria are satisfied on main as of commit 1c4234337:
/debate/ string references remain in api.py (grep returned no matches for "/debate/")/debates appears in nav.py Main dropdown (line 68): ("/debates", "Debates", "🗣")/debates route returns HTTP 200 via curl check1c4234337 dated 2026-04-17 by SciDEX Agent1c4234337d3a12363767f8e02d017adb7a985d95 — [Agora] api.py: fix broken /debate/ links → /debates/; nav.py: add Debates to top nav [task:cf4c46df-6fcb-4369-a411-98b64fec3adc]{
"_reset_note": "This task was reset after a database incident on 2026-04-17.\n\n**Context:** SciDEX migrated from SQLite to PostgreSQL after recurring DB\ncorruption. Some work done during Apr 16-17 may have been lost.\n\n**Before starting work:**\n1. Check if the task's goal is ALREADY satisfied (run the relevant checks)\n2. Check `git log --all --grep=task:YOUR_TASK_ID` for prior commits\n3. If complete, verify and mark done. If partial, continue. If not done, proceed.\n\n**DB change:** SciDEX now uses PostgreSQL. `get_db()` auto-detects via\nSCIDEX_DB_BACKEND=postgres env var.",
"_reset_at": "2026-04-18T06:29:22.046013+00:00",
"_reset_from_status": "done"
}