Skip to content

Releases: apollographql/apollo-ios

Version 0.15.1

04 Sep 16:49
Compare
Choose a tag to compare
  • Add platform name to framework bundle identifier to work around a change to app store submission. Please see the PR for more details. (#751)
  • Expose the initializer for GraphQLQueryWatcher so it can actually be instantiated. (#750)

Version 0.15.0

16 Aug 09:12
Compare
Choose a tag to compare
  • BREAKING: Finally swapped out URLSessionConfiguration on initializer for HTTPNetworkTransport to use URLSession directly instead. If you were previously passing in a configuration, first hand it to a URLSession instance and then pass that instance into the initializer.

    This allows many new things including:

    • Support for background sessions
    • Easier mocking through NSURLProtocol
    • Certificate pinning
    • Self-signed certificates
    • Metrics inspection
    • Authentication challenge handling

All these are pretty much entirely through the ability to use URLSessionDelegate directly since we're now accepting a URLSession you can declare yourself to be the delegate of rather than just the configuration. (#699, inspired by #265)

  • BREAKING, though hopefully in a good way: Significant updates to the Upload functionality to make it conform more closely to the GraphQL Upload Spec. Also added a goodly bit of documentation around this functionality. (#707)
  • Way better support for Swift Package Manager, especially for ApolloSQLite and ApolloWebSocket. (#674)
  • Created ApolloClientProtocol to match all public methods of ApolloClient for easier mocking. (#715, inspired by #693)

Version 0.14.0

07 Aug 20:09
Compare
Choose a tag to compare
  • BREAKING Updated codegen to use 2.17 of the Apollo CLI. Please see the full release notes for that version of the CLI, but in short:
    • Stops force-unwrapping and instead nil-coalesce to .none when the thing being unwrapped was a double-optional, which was causing some crashes
    • Fixes issue where removing redundant modifiers was a little too agressive
    • Fixes escaping for Self as a type name
    • Adds CaseIterable for all known cases of an enum. If you were adding this yourself previously, you'll have to take it back out.
    • Adds comment with original operation to operationDefinition, stripped excess whitespace from actual definition.
  • Added explicit support for Catalyst builds. (#688)
  • Added support for Int custom scalars. (#402)
  • Exposed clearCache directly on stores so a store being used by multiple clients can be more explicitly cleared. (#518)
  • Fixed an issue where an error on cache write would not be propagated correctly. (#673)
  • Updated supported Node version to the Long-Term Support version. (#672)

Version 0.13.0

23 Jul 09:38
Compare
Choose a tag to compare

PLEASE READ THESE RELEASE NOTES BEFORE INSTALLING IF YOU WERE USING AN OLDER VERSION!

  • SUPER-BREAKING: Updated a ton of completion closures that could use it to use Result instead of optional parameter / optional error. (#644). There are a few details to this one to be particularly aware of:

    • If you see a bunch of Swift build errors that are claiming Generic Parameter "Query" could not be inferred, that means you need to update your completion closure to take the single Result<Parameter, Error> parameter instead of the two (Parameter?, Error?) parameters.
    • Particularly around caching, if there are places where both parameters were nil in previous iterations, you will now get an Error. This will generally be a JSONDecodingError.missingValue, either as the direct error or as the underlying error of a GraphQLResultError. Please check out the changes to FetchQueryTests in PR #644 for a better look at how some of that has changed.
  • BREAKING: Updated the codegen to use v2.16 of the Apollo CLI. (#647). This is a major version change so some things need to be added, and some parameter names have changed:

    • You must add --target=swift so the CLI knows to generate Swift code.
    • If you were using --schema=schema.json, use --localSchemaFile="schema.json" instead (the quotes are required!).
    • If you were using --queries="$(find . -name '*.graphql')" to pass in an array of all your GraphQL files, use --includes=./*.graphql instead.

    If you get error messages about multiple versions of node when you attempt to run, delete the node_modules folder in your source root and rebuild.

    Upgrading fixes several issues:

    • operationName is now generated for all operations.
    • Trailing newlines are now added to all generated files.
  • NEW: Ability to upload files according to the GraphQL Multi-part request spec. (#626, #648, inspired by #116)

  • NEW: Now that operationName is generated for all operations, we're sending it along with all requests. (#657, inspired by #492)

  • NEW: We're also sending operationName as the X-APOLLO-OPERATION-NAME header and when an operationIdentifier is provided, sending that as the X-APOLLO-OPERATION-ID header. (#658)

  • NEW: Option to run VACUUM on your SQLite store when clearing to help obliterate all traces of data. (#652)

  • NEW: Auto-generated API documentation from inline comments. Now available on the website NOTE: Any manual changes made to markdown files will get overwritten, if you want to contribute to the docs, please add inline comments to the code and then I'll get the docs updated. (#642).

  • Made GraphQLResultError and its underlying error public for better error handling. (#655)

Version 0.12.0

17 Jul 16:05
Compare
Choose a tag to compare
  • BREAKING: Removed internal Result type in favor of Swift's built in Result type. This allows you to not have to prefix anything that uses the built-in result type with Swift.Result in places where you're using the Apollo SDK. (#641)
  • BREAKING: Set strict dependency versions for Starscream and SQLite.swift to prevent potential problems with Swift version conflicts. (#641).
  • BREAKING: Made Carthage dependencies for Starscream and SQLite.swift private so they're not automatically pulled in when trying to build just the main SDK with Carthage. If you're using the ApolloSQLite or ApolloWebSocket frameworks with Carthage, please read the updated documentation!. (#635, #641)
  • Fixed issue where GET requests were requiring AnyHashable instead of Any which made requests with Bool properties never send. (#628, big thanks to #624)

Version 0.11.1

11 Jul 15:50
Compare
Choose a tag to compare
  • Fixed missing Foundation imports for several classes that were causing issues with Buck and Swift Package Manager builds. (#620)
  • Updated version of SQLite.swift dependency to one that properly supports Swift 5. (#621)
  • Whole mess o'documentation updates. (#618)
  • Fixed a whitespace issue with one of the build scripts. (#618)
  • Made the GraphQLResult initializer public for testing. (#544)

Version 0.11.0

10 Jul 09:04
01045b5
Compare
Choose a tag to compare
  • BREAKING: Updated Podspec to preserve paths rather than embedding scripts in the framework. Updated instructions for embedding with CocoaPods. (#575, #610)
  • NEW: At long last, the ability to update headers on preflight requests, the ability to peer into what came to the URLSession and the ability to determine if an operation should be retried. (#602)
  • NEW: Added .fetchIgnoringCacheCompletely caching option, which can result in significantly faster performance if you don't need the caching. (#551)
  • NEW: Added support for using GET for queries. (#572, #599, #602)
  • Updated lib and dependencies to use Swift 5, and say so in the Podfile. (#522, #528, #561, #592)
  • Exposed a method to ping a WebSocket server to keep it alive. (#422)
  • Handling is always done on a handler queue. (#539)
  • Added documentation on the read and update operations for watching queries. (#452)
  • Updated build scripts for non-CocoaPods installations to account for spaces in project names or folders. (#610)
  • Fixed a code generation fail if you're using MacPorts instead of Homebrew to install npm. (#591)