refactor(wire): soft-deprecate the pure-Swift wire clients (removed in 2.0.0) - #173
Merged
Conversation
…n 2.0.0) Completion-design §8, the post-1.3.0-tag deprecation step: annotate the wire-specific public entry points — ZenohClient.init() and DDSClient.init() — with @available(*, deprecated, "... use the RCL backend. Removed in 2.0.0."). The umbrella .zenoh(locator:)/.dds(...) API is unchanged and NOT deprecated: it routes to the RCL backend where available and to the wire path elsewhere. Mechanics: - The public inits stay DESIGNATED (ZenohClient is non-final; turning its only designated init into a convenience delegate would break external subclass chaining — a 1.x freeze violation). A parallel package init(wireFallback:) is the non-deprecated seam for in-package callers, so makeDefaultSession's automatic wire fallback and the golden-oracle tests build with ZERO deprecation warnings. - Deprecated-init pin tests (themselves @available(*, deprecated)) assert the public inits keep constructing working clients through 1.x. - README gains the Deprecation section (recommended runtime, what is / is not deprecated, the physically-absent-vs-deprecated nuance per build variant); MIGRATION.md gains the 1.2 -> 1.3 recipe. API gate vs 1.2.0 unchanged (the annotations do not register as breakage; only the two pre-allowlisted additive enum cases remain); full suite, lint, and the zenoh-variant carve-out build all green. Signed-off-by: Yutaka Kondo <yutaka.kondo@youtalk.jp>
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Completion-design §8 — the post-1.3.0-tag deprecation step (§12 PR 4). The pure-Swift wire path is now formally deprecated; removal lands in 2.0.0.
ZenohClient.init()/DDSClient.init()carry@available(*, deprecated, message: "The pure-Swift wire path is deprecated; use the RCL backend. Removed in 2.0.0.")..zenoh(locator:)/.dds(...)route to the RCL backend where available and to the wire path elsewhere (Android; visionOS zenoh; Windows).package init(wireFallback:)is the non-deprecated in-package seam, somakeDefaultSession's automatic fallback and the golden-oracle tests build with zero deprecation warnings.@available(*, deprecated)) assert the public inits keep working through 1.x.Verification
Full suite green; zero deprecation warnings in the package's own build;
swift format lint --strictclean; API gate vs 1.2.0 unchanged (annotations do not register as breakage; only the two pre-allowlisted additive enum cases remain); zenoh-rmw variant carve-out build green.