You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This PR bumps the Apple SDK to version 17.1.1, removing the admin-only Advisor service and its five associated model files, and adding a sizeActual field to the File model.
Advisor removal: Advisor.swift, Insight, InsightCTA, InsightList, Report, and ReportList are all deleted; the CHANGELOG now correctly lists all five removed models and the four matching example docs are gone.
File model update: sizeActual: Int is added as a required (non-optional) field, decoded with a hard container.decode and force-cast as! Int in from(map:). Clients on SDK 17.1.1 pointing at a server version that does not yet include this field will receive a DecodingError.keyNotFound or a fatal crash on every file-related response (noted in a prior review comment that remains unaddressed).
Version bump: x-sdk-version header and the README SPM snippet updated to 17.1.1.
Confidence Score: 4/5
The Advisor removal is clean, but sizeActual is decoded as a hard-required field with a force-cast, meaning any client targeting a server that omits this field will crash or throw on every file API call.
The Advisor deletions are straightforward and correctly reflected in the changelog. The only meaningful risk is in File.swift: sizeActual is decoded with container.decode (not decodeIfPresent) and accessed via as! Int in from(map:), with no server-version gating (x-appwrite-response-format is still 1.9.5). A client on this SDK version communicating with an older Appwrite server will hit a DecodingError.keyNotFound or a runtime crash on every storage endpoint. This issue was raised in a previous review round and has not yet been addressed.
Sources/AppwriteModels/File.swift — the sizeActual field decoding and force-cast
Important Files Changed
Filename
Overview
Sources/AppwriteModels/File.swift
Adds required (non-optional) sizeActual: Int field; decoded with hard decode and force-cast as! Int — will throw/crash against servers that don't return this field yet
Sources/Appwrite/Services/Advisor.swift
Deleted: entire Advisor service removed as it was admin-only and not intended for client SDKs
Sources/Appwrite/Client.swift
Version bump from 17.1.0 to 17.1.1 in SDK header; no functional changes
CHANGELOG.md
17.1.1 entry now correctly lists all five removed models (Insight, InsightCTA, InsightList, Report, ReportList) and the added sizeActual field
README.md
SPM dependency version reference updated from 17.1.0 to 17.1.1; no other changes
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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.
This PR contains updates to the Apple SDK for version 17.1.1.
What's Changed
Advisorservice andInsight,InsightCTA,InsightList,Report,ReportListmodels (admin-only endpoints, not intended for client SDKs)sizeActualfield toFilemodel