log
log copied to clipboard
Stabilize kv_unstable
This is part of #328
I think we've explored enough of this design space now and the API has been in use within the tide
project for some time now with their own kv-capable logging macro.
By stabilizing just the backend (non-macro-supported) kv
module we can let users depend on this with confidence so that projects like tracing
can also utilize it.
Migration path
The kv
API will remain an opt-in optional API. All features that currently begin with kv_unstable
will be changed to kv
. We can keep these old unstable features around for a while if we need.
Any other changes that are needed should be included here.
Steps
- [ ] Public API review of the
kv
module - [ ] Stabilize
sval
- [ ] Stabilize
value-bag
- [ ] Documentation and examples
cc @yoshuawuyts
I don't know what the plan is for the kv_unstable_std
feature, but can that be removed? Surely most users mean to enable kv_unstable_std
if std
and kv
are enabled.
@Thomasdezeeuw unfortunately it’s a limitation of Cargo features. Since it’s not possible to activate a feature of a dependency when two unrelated features are active we need one that covers them both.
@KodrAus in the code you can use #[cfg(all(feature = "kv", feature = "std"))]
in stead of #[cfg(feature = "kv_unstable_std")]
, removing the kv_unstable_std
feature.
@Thomasdezeeuw we can do that in code, but we also have dependencies that need their own std
features enabled too.
@KodrAus could you make another release to try the new macro syntax?
@Thomasdezeeuw Will do! I'll get the ball rolling on this now.
@KodrAus any update on a release? We've been using the git version without issues for a while (including the new macro syntax).
@Thomasdezeeuw I've been waiting for some feedback from the wider project on https://github.com/rust-lang/log/issues/343#issuecomment-1002851191, but it's been a bit quiet. I'm pretty confident in the direction we're going though and that we're not heading down a path we'll regret later so will push ahead.
I've opened #485 to get a release out the door. I'm just going to run through the diff, but if you had a chance to take a look too @Thomasdezeeuw that would be much appreciated! :bow: