Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
[ECO-5082] feat: presence basic implementation #42
[ECO-5082] feat: presence basic implementation #42
Changes from all commits
dbbfe45
d6b38ba
492fba8
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
🛠️ Refactor suggestion
Documentation needs update to match implementation
The documentation refers to
Ably.RealtimePresenceParams
but the method signature uses individual parameters. Consider using a typed parameter object as suggested in previous reviews for better API clarity and future extensibility.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.
Add safe casting for JsonObject data extraction
The current implementation uses an unsafe cast that could fail at runtime. Consider using safe cast and proper error handling.
📝 Committable suggestion
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.
Add safe casting in presence event creation
Similar to the get method, this uses an unsafe cast that could fail at runtime.
📝 Committable suggestion
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.
💡 Codebase verification
Implementation needed across multiple components
The
onDiscontinuity
method is not implemented in multiple core components: Messages, Presence, Typing, RoomReactions, and Occupancy. This appears to be a systematic gap in implementing theEmitsDiscontinuities
interface across the codebase. The interface is defined to handle discontinuity events with error information, but none of the implementations are complete.chat-android/src/main/java/com/ably/chat/Messages.kt
chat-android/src/main/java/com/ably/chat/Presence.kt
chat-android/src/main/java/com/ably/chat/Typing.kt
chat-android/src/main/java/com/ably/chat/RoomReactions.kt
chat-android/src/main/java/com/ably/chat/Occupancy.kt
🔗 Analysis chain
Implement onDiscontinuity method
The
onDiscontinuity
method is marked as not implemented. Please clarify if this is intentional or if it should be implemented as part of this PR.Would you like help implementing this method?
Let me check the implementation in other files to understand the expected behavior.
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
Length of output: 357
Script:
Length of output: 944
Script:
Length of output: 2233
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.
We can now safely remove this helper method right