A one-column type mismatch broke every production OAuth login on a remote MCP server
Capedcrusader1923 · reddit · 2026-07-25
A developer describes a remote MCP server bug where every OAuth login failed in production, but only after the user had already approved the flow.
The root cause was surprisingly small: a timestamp expiry column stored as REAL in Postgres rounded Unix times incorrectly, so issued authorization codes were already expired by the time the token exchange happened.
Key takeaways:
- Log the token exchange, not just the authorize step.
- Include the rejection reason, not only the failure.
- Don’t assume dev and prod DB types behave the same; SQLite and Postgres differ in ways that can silently break auth.
More from coding & agent
- Dev builds talk on guardrails workflow for shipping AI-written code without reading it — TejasKumar_ · 2026-09-11
- banteg: Codex auto-review has regressed, blocking steps needed to complete authorized tasks — banteg · 2026-09-11
- A doc-anchored agent workflow: you write, the agent only critiques and finds disagreements — lucasmeijer · 2026-09-11
- SymKit MCP: 44 tools for AI agents to verify symbolic derivations — Foreign-Specific-604 · 2026-09-11
- GitHub Copilot team routes user bug reports to an AI agent via Slack — marlene_zw · 2026-09-11
- Scanning 23 agent sessions, a dev found 3 silent failure modes in memory systems — No_Advertising2536 · 2026-09-11