All Versions
Latest Version
Avg Release Cycle
76 days
Latest Release

Changelog History
Page 1

  • v4.4.3 Changes


    • ๐Ÿ›  Fix: No more NPEs when the building project uses Kotlin 1.7.20.
  • v4.4.2 Changes


    • ๐Ÿ›  Fix: Use KotlinProjectExtension to access source sets.
    • ๐Ÿ›  Fix: Improve support for ZIP artifacts.
    • ๐Ÿ›  Fix: When set to true, buildersOnly will take precedence over javaInterop when generating Kotlin.
    • ๐Ÿ›  Fix: Support nested extensions in a message.
  • v4.4.1 Changes


    • ๐Ÿ†• New: Check HTTP2 protocol is set for passed client to GrpcClient.
    • ๐Ÿ†• New: Add buildersOnly option for Java and Kotlin target, setting it to true will change the visibility of generate types' constructor to non-public.
    • ๐Ÿ›  Fix: Properly define api dependency for okio in wire-schema.
    • ๐Ÿ›  Fix: Sort input locations so they match on all platforms.
    • ๐Ÿ›  Fix: Avoid NPEs with kotlin 1.7.20 around source sets.
    • โšก๏ธ Update: Bumped KotlinPoet to 1.12.0.
  • v4.4.0 Changes


    • ๐Ÿ†• New: Custom schema handlers! Wire lets you now plug in your own logic to deal with the protobuf schema the way you want. Check [our documentation][custom-handlers-doc] for details. You can also check our [recipe directory][custom-handlers-recipes] for examples. Note that this API obsoletes the CustomHandlerBeta type Wire had until now.
    • ๐Ÿ†• New: You can now easily create an in-memory protobuf schema with the new SchemaBuilder class. This lives in the new wire-schema-tests artifact. For usage examples, check the tests in [custom handler recipes][custom-handlers-recipes].
    • ๐Ÿ’ฅ Breaking: the wire-profiles artifact has been removed and is now inlined in wire-schema.
    • ๐Ÿ’ฅ Breaking: CoreLoader 's isWireRuntimeProto methods are now static.
    • ๐Ÿ’ฅ Breaking: SchemaLoader and related classes have been moved from wire-compiler to wire-schema.
    • ๐Ÿ†• New: Support packed and map fields when converting to/from JSON with Kotlin.
    • ๐Ÿ†• New: Support typesafe accessors and version catalogs in Wire plugin.
    • ๐Ÿ†• New: Generate annotations for repeated options.
    • ๐Ÿ†• New: Allow parsing of oneof options.
    • ๐Ÿ†• New: Support map fields in options.
    • ๐Ÿ†• New: Add macosArm64 support to the KMP projects supporting mac.
    • ๐Ÿ›  Fix: Properly deal with maps of scalar types, deserializing missing scala key/value into identity.
    • ๐Ÿ›  Fix: Fix a crash where ProtoMember was populated with the wrong data.
  • v4.3.0 Changes


    • ๐Ÿ†• New: reserved tags and names in enum types are now honoured by Wire.
    • ๐Ÿ›  Fix: max keyword is now correctly parsed for enum types.
    • ๐Ÿ›  Fix: Wire now writes minus double zeros and minus float zeros on proto3.
    • ๐Ÿ›  Fix: Wire doesn't write google wrappers types' identity values anymore.
    • ๐Ÿ›  Fix: CoreLoader correctly loads .proto files present in the resources of the project.
    • ๐Ÿ›  Fix: Propagate GrpcExceptions in GrpcCalls.
    • ๐Ÿ›  Fix: Change GrpcCall.isCanceled to honor OkHttp cancellations.
  • v4.2.0 Changes


    • New: Publish a [bill of materials (BOM)][bom] for Wire. Depend on this from Gradle or Maven to keep all of your Wire artifacts on the same version, even if they're declared via transitive dependencies. You can even omit versions when declaring other Wire dependencies.

      dependencies {
        implementation("com.squareup.wire:wire-compiler")      // No version!
        implementation("com.squareup.wire:wire-gradle-plugin") // No version!
        implementation("com.squareup.wire:wire-grpc-client")   // No version!
        // Etc.
  • v4.1.1 Changes


    • Fix: Print target name in ConsoleWireLogger.
    • Fix: Throw early when field or constant names start with a digit.
    • Update: Bumped SwiftPoet to 1.3.1.
    • Fix: Wire will not generate annotations for repeated options.
  • v4.1.0 Changes


    • New: When using Wire JSON factories, you can now override the proto3 behavior of skipping default values when writing JSON. Set writeIdentityValues to true for either WireJsonAdapterFactory or WireTypeAdapterFactory to enable it.
    • Breaking: WireLogger methods has been refactored to remove platform dependencies and allow more precise callbacks. We might add new methods in the future for better logging still.
    • Removal: The dry-run option on WireCompiler has been removed.
    • Swift: WireCompiler podspec is now backup by a jar so consumers will not have to locally build it on pod install.
  • v4.0.1 Changes


    • Fix: Don't fail at compilation when an enum is in a oneof for Swift generation.
  • v4.0.0 Changes


    • New: Add 'nameSuffix' parameter for configuring generated service-class names in Kotlin.
    • New: Define oneofName in @WireField.
    • New: Enable iosSimulatorArm64 for Kotlin multiplatform.
    • New: Expose the source .proto file at ProtoAdaper.sourceFile. This is null for built-in types and types generated prior to this release.
    • New: Generate Kotlin code whose members match the declaration order of the corresponding .proto files. In previous releases, generated members were sorted by kind (fields, oneofs), then by declaration order. With this update only declaration order is used. Note that this will change the encoded-bytes of these messages. This change is both forwards and backwards-compatible. Identical encoding of equal messages across Wire releases is typical but not guaranteed, and this is a rare release that changes that encoding. If you do cryptographic hashes on encoded proto messages, you will notice that the hashes are different in this release.
    • New: Option in SchemaLoader to exhaustively load imported files. By default we only load what's immediately necessary to generate code; this new option loads everything reachable into the schema.
    • New: Programmatic API to prune schemas. See Pruner in wire-schema.
    • New: SchemaLoader doesn't extend the Closeable interface anymore.
    • New: Support rpcRole = 'none' in the Gradle plugin to generate neither client nor server code.
    • New: Support for Android variants.
    • New: Support for glob syntax in srcJar includes.
    • New: Support for special float literals.
    • New: Swift support Timestamp and Duration.
    • New: The Wire plugin requires an output to be set. Before, it would generate Java code by default; it will now throw if there are no [output][wire-customizing-output] defined.
    • New: The default value of emitAppliedOptions for our Java and Kotlin target is now set to true.
    • New: Wire should build and execute properly on Windows.
    • New: @WireRpc has a new sourceFile attribute.
    • New: GrpcClient.Builder.minMessageToCompress() configures which messages are compressed. This will completely disable compression if the size is Long.MAX_VALUE. We've seen problems where some Golang gRPC servers don't support compression; setting this to MAX_VALUE is necessary to interop with them.
    • New: SchemaReflector is our initial implementation of the [gRPC Server Reflection Protocol][reflect]. Note that although we implement the business logic of gRPC reflection, we don't offer a gRPC server built into Wire.
    • New: wire-reflector bundles gRPC's reflection.proto which it is built upon.
    • New: wire-runtime exposes a com.squareup.wire.VERSION constant reflecting the project version.
    • New: change the Gradle plugin so that (unstable) custom handlers can be configured with instance instead of with a class name.
    • Fix: Be more aggressive about loading transitive files with SchemaLoader.loadExhaustively.
    • Fix: Bugs in JSON serialization of builder-less Kotlin types have been addressed.
    • Fix: Compile Kotlin/JS with both LEGACY and IR compilers.
    • Fix: Deep copy metadata on GrpcCall.clone().
    • Fix: Don't break task caching by using absolute paths in the Gradle plugin. Wire now uses project-relative paths in any attribute that is used as a cache key.
    • Fix: Don't crash encoding schemas when an option contains a repeated field, an enum, or a double.
    • Fix: Don't depend on moshi-kotlin in wire-moshi. This caused a transitive dependency on kotlin-reflect, which we neither needed nor wanted.
    • Fix: Don't generate invalid code when an enum constant is named name or ordinal.
    • Fix: Don't re-use the cache if protobuf inputs have changed.
    • Fix: Emitting proper protobuf format for option values defined as a list of enum constants.
    • Fix: Explicitly defined Wire gRPC server generation as experimental: the feature isn't complete.
    • Fix: Generate @Deprecated annotations on deprecated messages, fields, enums, and enum constants.
    • Fix: Handle out of order proto fields when initializing Kotlin constructors.
    • Fix: Handle writing/reading exceptions for duplex calls in Wire gRPC.
    • Fix: In Java, rename instances to avoid field and class name conflicts.
    • Fix: Locate files in the root package when importing.
    • Fix: Memory fixes found with Address Sanitizer in Swift.
    • Fix: Permit values other than 0 and 1 when decoding protobuf-encoded booleans. Previously we threw an IOException for other values; now all non-zero values are true.
    • Fix: Redact boxed OneOf fields.
    • Fix: Redacted Kotlin scalars now respect nullability.
    • Fix: Retain field order when emitting a schema as .proto files.
    • Fix: Reverse the topological sort of dependent files in SchemaReflector. We had problems with grpc-curl which expects the requested file to be listed first.
    • Fix: Support Kotlin-generated annotations on Java fields.
    • Fix: Support for serializing builder-less Kotlin generated classes to JSON.
    • Fix: Support reporting errors in CustomHandlerBeta.
    • Fix: Suppress deprecation warnings on generated enum's fromValue method in Kotlin.
    • Fix: Swift adapters will throw an error when encountering an unexpected ProtoReader.beginMessage() rather than calling fatalError().
    • Fix: Update the Wire Gradle plugin to clear the output directory before generating code. This prevents the need to do a clean build after removing a message type.
    • Fix: Update the Wire Gradle plugin to register generated .java sources with the Java compiler. Previously this was broken if the Kotlin plugin was installed.
    • Fix: Use Gradle's logging mechanism to reduce output when Wire generates code.
    • Fix: Use correct type when referencing a custom adapter in Kotlin generated code.
    • Fix: Use relative path sensitivity and file collection.
    • Fix: Validate enum constant uniqueness for the entire package.
    • Fix: Wire Gradle plugin tasks have been modernized with configuration caching support.
    • Fix: Wire will not generate respective built-in types for Java, Kotlin, and Swift generation. Those are usually the google types for which Wire will provide its own implementation.
    • Upgrade: Update KotlinPoet to 1.8.0.
    • Upgrade: [OkHttp 4.9.3][okhttp_4_9_3].
    • Upgrade: [Okio 3.0.0][okio_3_0_0]. We now use Okio 3's FileSystem in SchemaLoader, which makes it easier to load .proto files from the classpath. This is binary-incompatible with the Okio 3.0 alpha releases.
    • Bye: Drop support for emitKotlinxSerialization.