Repository navigation
[CHA-5933] test: run scheduled message tests unconditionally - #280
Conversation
The CI app now has scheduled messages enabled, so drop the STREAM_SCHEDULED_MESSAGES_ENABLED gate. The server rounds a future scheduled_at up to the next whole UTC minute, so the create and update tests floor the requested time to a whole minute and assert it exactly. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
CI is red on exactly the tests this PR un-skips. In the
The failure happens on the send request itself, before any of the new minute-rounding assertions run, so the assumption that the CI app has the feature enabled hasn't been shown to hold here. One data point: the .NET SDK's equivalent live tests (stream-chat-net#219) no longer skip when the feature is off, and its CI is green, so the .NET CI app does have scheduled messages enabled. Worth checking:
This shouldn't merge until the job is green. |
|
Thanks, root-caused. The Java CI app (31197, us-east4:c1) has Server fix: https://github.com/GetStream/chat/pull/19652. This PR stays unmerged until that's deployed on c1 and CI is green. Agree on the empty error message: a 500 body loses its details in the SDK's error parsing. I'll track that separately. |
Lombok @Singular always builds an empty map, so every send carried "reaction_scores":{}. Servers before GetStream/chat#19652 store that legacy field as invalid JSON and 500 on scheduled sends. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
TLDR
chat_scheduled_messages_enabled), soScheduledMessageIntegrationTestno longer needs theSTREAM_SCHEDULED_MESSAGES_ENABLEDgate. It was never set in CI, so these tests have never run. The gate is removed and they now run on every PR and in the weekly scheduled job.scheduled_atup to the next whole UTC minute (minimum now + 1 minute). The create and update tests now floor the requested time to a whole minute, which the server stores unchanged, and assert it exactly instead of to the second.🤖 Generated with Claude Code
Note
Low Risk
The serialization tweak only drops an empty legacy field from outbound message requests; integration coverage now assumes CI keeps scheduled messages enabled.
Overview
Scheduled message sends no longer include an empty
reaction_scoresobject in the JSON body.MessageRequestObjectnow uses@JsonInclude(NON_EMPTY)so Lombok’s@Singularmap is omitted when unset, avoiding{}that breaks scheduled sends on servers before chat#19652. A unit test asserts the scheduled send payload does not containreaction_scores.Integration tests for scheduled messages run unconditionally: the
STREAM_SCHEDULED_MESSAGES_ENABLEDgate is removed now that CI’s app has the feature on. Create/update tests floorscheduled_atto a whole UTC minute (matching server rounding) and compareDatevalues exactly instead of by second.Reviewed by Cursor Bugbot for commit 49ec51b. Bugbot is set up for automated code reviews on this repo. Configure here.