-
Notifications
You must be signed in to change notification settings - Fork 4
feat: Swift SDK update for version 13.3.0 #46
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
Conversation
WalkthroughThis pull request bumps the SDK version from 13.2.2 to 13.3.0. The changes include a new changelog entry documenting three new Realtime service callbacks (onOpen, onClose, and onError), version updates in the Swift Package Manager example within the README, and an updated x-sdk-version header value in the Client class. Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes The changes are homogeneous version number updates across three files with consistent patterns. The CHANGELOG entry is straightforward documentation. No logic modifications, structural changes, or complex reasoning per file is required. Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
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. Comment |
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
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
CHANGELOG.md(1 hunks)README.md(1 hunks)Sources/Appwrite/Client.swift(1 hunks)
🔇 Additional comments (2)
README.md (1)
36-36: LGTM! Version update is consistent.The Swift Package Manager dependency version has been correctly updated to match the new SDK version 13.3.0.
Sources/Appwrite/Client.swift (1)
24-24: LGTM! SDK version header correctly updated.The
x-sdk-versionheader has been updated to "13.3.0", ensuring the server can correctly identify the SDK version during API communication.
| ## 13.3.0 | ||
|
|
||
| * Add `onOpen`, `onClose` and `onError` callbacks to `Realtime` service |
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.
🧩 Analysis chain
Verify that Realtime service callbacks are implemented.
The changelog documents new callbacks (onOpen, onClose, onError) for the Realtime service, but the implementation is not visible in the provided files.
Run the following script to verify the Realtime service contains these callbacks:
🏁 Script executed:
#!/bin/bash
# Description: Verify that the new Realtime callbacks exist in the codebase
# Search for onOpen, onClose, and onError callback definitions in Realtime service
echo "Searching for onOpen callback..."
rg -n "onOpen" --type swift -C 3
echo -e "\nSearching for onClose callback..."
rg -n "onClose" --type swift -C 3
echo -e "\nSearching for onError callback..."
rg -n "onError" --type swift -C 3Length of output: 102
🏁 Script executed:
#!/bin/bash
# Description: Broader verification of Realtime service and callbacks
# Find files related to Realtime
echo "Finding Realtime-related files..."
fd -i realtime --type f
echo -e "\n---\nSearching for onOpen, onClose, onError without type restrictions..."
rg -n "(onOpen|onClose|onError)" --type-list | head -20
echo -e "\n---\nSearching for callback patterns in codebase..."
rg -n "onOpen|onClose|onError" -C 2
echo -e "\n---\nSearching for Realtime class/service definition..."
rg -n "class Realtime|struct Realtime|interface Realtime|export.*Realtime" -C 3Length of output: 773
🏁 Script executed:
#!/bin/bash
# Description: Verify repository structure and check for any service implementations
# List directory structure
echo "Repository structure:"
find . -type f -name "*.md" -o -name "*.ts" -o -name "*.js" -o -name "*.swift" -o -name "*.kt" | head -30
echo -e "\n---\nAll files in repo:"
find . -type f | grep -v ".git" | head -50
echo -e "\n---\nSearching for 'service' or 'callback' mentions:"
rg -n "service|callback" -i | head -20Length of output: 6913
🏁 Script executed:
#!/bin/bash
# Description: Final verification - search for any Realtime references
echo "Searching for 'Realtime' anywhere in codebase:"
rg -n -i "realtime"
echo -e "\n---\nListing all Swift files in Services directory:"
find ./Sources/Appwrite/Services -name "*.swift" -type f | sortLength of output: 813
Realtime service and callbacks are not implemented.
The changelog entry documents onOpen, onClose, and onError callbacks for a Realtime service, but verification shows:
- No
Realtime.swiftservice file exists in./Sources/Appwrite/Services/ - No references to "Realtime" or these callbacks exist anywhere in the codebase
- This appears to be premature documentation of unimplemented features
Either add the Realtime service implementation with these callbacks or remove the changelog entry.
🤖 Prompt for AI Agents
In CHANGELOG.md around lines 3 to 5, the entry claiming “Add `onOpen`, `onClose`
and `onError` callbacks to `Realtime` service” is documenting functionality that
does not exist; either implement the Realtime service or remove the changelog
entry. To fix: if implementing, add a new
Sources/Appwrite/Services/Realtime.swift matching your project’s service
patterns (namespace, initialiser, network client usage) and expose
onOpen/onClose/onError callback hooks consistent with other service APIs and
unit tests; ensure the file is exported in the package manifest if required and
add references/tests. Otherwise, remove or amend the CHANGELOG.md lines to
reflect the actual implemented features so the changelog matches the codebase.
This PR contains updates to the Swift SDK for version 13.3.0.
Summary by CodeRabbit
onOpen,onClose, andonErrorcallbacks for the Realtime service.