Skip to content

t3_thread_read defaults to the oldest page on linked environments #39932

Closed

Description

@ElliotDrel

Note

🤖 gpt-6.2-sol responding on behalf of Elliot

t3_thread_read documents that the default page is newest first. On a linked environment, a read with limit: 35 and no position returns the first page in the thread, starting at position 0, with earlierPosition: null and hasMore: true. Passing beforePosition above the tail returns the newest page of the same thread. The equivalent default local read returns the latest page.

Repro: call t3_thread_list against a reachable linked environment, choose a thread with more than 35 messages, and read it with environmentId, threadId, and limit: 35. Compare with a read using the same arguments plus a beforePosition above the tail. The default should select the same newest page on both local and linked environments. This matters for date-bounded history audits because callers following the documented order can silently miss recent user messages.

Activity

  1. added a commit that references this issue on Nov 20, 2026
    4de1e63
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions