-
Notifications
You must be signed in to change notification settings - Fork 61
Merge main into integration/liveobjects branch 2025-04-17
#2014
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merge main into integration/liveobjects branch 2025-04-17
#2014
Conversation
Fix realtime annotation subscribe signature
Missed from the initial pr due to late-stage redesign. Doesn't actually fix any bug since it's essentially just internal typings for fields that no internal code touches right now, but they should still be there for the benefit of maintainers
This was missed in 7d98957
Add ANNOTATION_* channel modes to ResolvedChannelMode types
Annotation: add a couple of missing fields
release/2.7.0
WalkthroughThis update introduces version 2.7.0, adding two new channel modes: Changes
Sequence Diagram(s)sequenceDiagram
participant Client
participant Channel
participant Annotations
Client->>Channel: Set channel mode to ANNOTATION_PUBLISH/ANNOTATION_SUBSCRIBE
Client->>Channel: Publish message with annotations
Channel->>Annotations: Store annotation (with optional name, count)
Client->>Annotations: Subscribe to annotations
Annotations-->>Client: Receive annotation (Annotation object)
Possibly related PRs
Suggested reviewers
Poem
Tip ⚡💬 Agentic Chat (Pro Plan, General Availability)
✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (1)
src/common/lib/types/annotation.ts (1)
62-63: Document new optional properties.
You've addedname?: stringandcount?: numbertoAnnotationandWireAnnotation. To improve clarity, consider adding JSDoc comments for these fields describing their semantics and usage.Also applies to: 92-93
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
package-lock.jsonis excluded by!**/package-lock.json
📒 Files selected for processing (5)
CHANGELOG.md(1 hunks)ably.d.ts(4 hunks)package.json(1 hunks)src/common/lib/types/annotation.ts(2 hunks)src/platform/react-hooks/src/AblyReactHooks.ts(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (7)
- GitHub Check: test-node (20.x)
- GitHub Check: test-browser (webkit)
- GitHub Check: test-browser (firefox)
- GitHub Check: test-node (18.x)
- GitHub Check: test-node (16.x)
- GitHub Check: test-browser (chromium)
- GitHub Check: test-npm-package
🔇 Additional comments (10)
package.json (1)
4-4: Verify version bump consistency.
The package version has been updated to"2.7.0". Please confirm this aligns with your release tagging, CHANGELOG entry, and any automated release workflows (e.g., CI/CD scripts).src/platform/react-hooks/src/AblyReactHooks.ts (1)
15-15: Confirm version constant matches package.json.
Theversionconstant is updated to'2.7.0', matching the bump inpackage.json. Ensure these stay in sync for future releases.CHANGELOG.md (3)
5-5: Validate new changelog entry header.
The header## [2.7.0] (2025-04-17)correctly reflects the release version and date.
7-8: Review feature bullets for accuracy.
The bullets introducingANNOTATION_PUBLISH&ANNOTATION_SUBSCRIBEmodes and support forchannel.annotationsreference PR #1953 correctly.
10-11: Approve bug fix and type update bullets.
The fix for thedeactivatedevice auth issue (#2000) and the optional callback type update are accurately documented.ably.d.ts (5)
920-921: Documentation improvement for SUBSCRIBE mode.The description for the
SUBSCRIBEmode has been refined to clarify that the client will receive messages. This improves clarity in the API documentation.
929-930: Documentation improvement for PRESENCE_SUBSCRIBE mode.The description for the
PRESENCE_SUBSCRIBEmode has been refined to clarify that the client will receive presence messages. This improves clarity in the API documentation.
939-946: Addition of new annotation channel modes.Two new channel modes have been added to support the annotations feature:
ANNOTATION_PUBLISH: Allows clients to publish annotationsANNOTATION_SUBSCRIBE: Allows clients to receive annotationsThis addition properly extends the type system to support the new annotation functionality.
962-964: Updated ResolvedChannelMode union type with new annotation modes.The
ResolvedChannelModeunion type has been extended to include the new annotation-related channel modes, ensuring they are recognized as valid options throughout the SDK.
2119-2119: Updated RealtimeAnnotations.subscribe method signature.The
subscribemethod signature has been updated to use theAnnotationtype for its listener callback instead ofPresenceMessage. This aligns the type system with the new annotation feature and ensures type safety when working with annotations.
|
|
||
| - Adds `ANNOTATION_PUBLISH` and `ANNOTATION_SUBSCRIBE` channel modes [\#1953](https://github.com/ably/ably-js/pull/1953) | ||
| - Adds support for message annotations via `channel.annotations` [\#1953](https://github.com/ably/ably-js/pull/1953) | ||
| - The message action `meta.occupancy` is now renamed to `meta`. Similarly, `MessageActions.META` is now `MessageActions.META` [\#1953](https://github.com/ably/ably-js/pull/1953) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix redundant bullet text.
The second half of this bullet reads "MessageActions.META is now MessageActions.META", which is tautological. It likely should state that MessageActions.META_OCCUPANCY has been renamed to MessageActions.META. Please correct this.
Merge changes from the next PRs into
integration/liveobjects:into the integration/liveobjects branch. No changes made during merge conflict resolution.
Summary by CodeRabbit
New Features
Bug Fixes
Other Changes