Provide environment information
N/A
Describe the bug
Runs that have been running for 24+ hours (or created more than 24 hours ago) do not appear in useRealtimeRunsWithTag on the client, even when passing createdAt: '1w'. They are visible via runs.list and in the dashboard.
Expected: With createdAt: '1w', all runs with the given tag from the last week (including long-running ones) are streamed and appear in the hook.
Actual: The realtime endpoint caps the createdAt filter to REALTIME_MAXIMUM_CREATED_AT_FILTER_AGE_IN_MS (default 24h). So only runs created in the last 24 hours are included; runs older than that are excluded regardless of the client's createdAt value.
Reproduction repo
n/a
To reproduce
- Create a run with a tag and let it run (or sit in a waiting state) for 24+ hours.
- In the app, use
useRealtimeRunsWithTag('your-tag', { createdAt: '1w' }).
- The run does not appear in the hook's
runs array, but it does appear in runs.list and in the dashboard.
Additional information
- Root cause:
apps/webapp/app/services/realtimeClient.server.ts → #calculateCreatedAtFilter clamps the filter to env.REALTIME_MAXIMUM_CREATED_AT_FILTER_AGE_IN_MS (default 24h in env.server.ts).
- No client-side workaround; the cap is applied server-side.
- Fix: increase the default (or make it configurable), or allow the client's requested window up to a defined max.
Provide environment information
N/A
Describe the bug
Runs that have been running for 24+ hours (or created more than 24 hours ago) do not appear in
useRealtimeRunsWithTagon the client, even when passingcreatedAt: '1w'. They are visible viaruns.listand in the dashboard.Expected: With
createdAt: '1w', all runs with the given tag from the last week (including long-running ones) are streamed and appear in the hook.Actual: The realtime endpoint caps the
createdAtfilter toREALTIME_MAXIMUM_CREATED_AT_FILTER_AGE_IN_MS(default 24h). So only runs created in the last 24 hours are included; runs older than that are excluded regardless of the client'screatedAtvalue.Reproduction repo
n/a
To reproduce
useRealtimeRunsWithTag('your-tag', { createdAt: '1w' }).runsarray, but it does appear inruns.listand in the dashboard.Additional information
apps/webapp/app/services/realtimeClient.server.ts→#calculateCreatedAtFilterclamps the filter toenv.REALTIME_MAXIMUM_CREATED_AT_FILTER_AGE_IN_MS(default 24h inenv.server.ts).