Replies: 2 comments
-
|
tbf the reason there wasn't much discussion - and i did ask around - was that everyone i spoke to was was happy to get rid of it. (specifically, my would a feature flag and deprecation path had been better, yes, if it was practical. if it is truly that big of a pain, you can ask k8s-openapi directly? maybe if you are less sarcastic you will be successful. |
Beta Was this translation helpful? Give feedback.
-
At least the current newtyping API wouldn't be able to be maintained like that, since you'd still have to decide on some canonical type for A feature flag wouldn't help much here, since feature flags should only be for additive changes.
As things look today, yes. There'd be little point in keeping things different between the crates "just because". "most of that codebase is generated" is also kind of a misnamer in these days of "AI" slopware. k8s-openapi maintains its code generator, and decides on the design tradeoffs of the generated code.
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Current and expected behavior
Here are the reasons I think this is a bug:
jiffreplacechrono"behind a feature flag." An "unstable" feature flag + migration path, if deprecation ofchronowas inevitable, would have been the correct way to do it, given thatjiffis less than 2 years old.chronoworks fine. It wasn't broken. Why fix something that was not broken? Maybe minor edge cases? Maybe it's not maintained as much? I see the latest update tochronocrate was pretty recent. Granted it has issues but it's the most ubiquitous and supported currently. It worked perfectly. Never had a single issue withchronoinkube-rs. Hasn't anyone these days heard of "if it aint broke, don't fix it," or is that idea gone with the wind?k8s-openapiauthor ripped outchronoand replaced it withjiff... because, "Moms like you usejiff?" Did not use the feature flag as requested by the issue author.kube-rsfollowed suit because, "alignment" and "dependency reduction"? Sokube-rsis basically "hostage" to whateverk8s-openapiauthor decides to do, even though most of that codebase is generated?Not saying
jiffis a bad crate. Maybe it's great. Maybe it's much better thanchrono. Not saying it isn't. I've never even seen or heard of it before, but boy is it suddenly popular! But it's modeled after JavaScript's newTemporaland has a much smaller "timespace" thanchrono. Maybe because it's JavaScript compatible or something? Seems like a downgrade to me, maybe not. Maybe this will allowkube-rsto work well in WASM? I can see that, and I get it, if that's the case, you can write a WASM kube client, great.But no discussion, no community feedback, no RFC, no
#[deprecated]path, nothing.Who else uses
jiffbesidesk8s-openapi, nowkube-rs, and "Moms like you"?Is this really the way things are starting to be done in the Rust ecosystem now? Backwards compatibility no longer matters?
There are no
From<Chrono<Utc>>impls so now we have to write a bunch of global helpers and remember to use those? Because of the orphan rule, we cannot write our ownFrom<T>impls for this!!This really imposes a lot of extra work on us, to wrap every single call from
Time(now)toTime(convert_from_chrono_to_timestamp(now)). Easy in small codebase. Not so much in larger codebase.Just not very Rusty. I'm not impressed with this "move fast and break things" decision without any community discussion over it. But alas, the decision has been made, right or wrong, so is it too late to fix this?
Possible solution
Push back on the
k8s-openapiauthor to put a feature gate as requested.Better yet, work with
k8s-openapito make a trait for which you canimpl Fromin an infallible way (clamp to valid ranges if you have to) from anytimecrate, now that everyone and their brother is authoring them.There are a number of better migration paths than the somewhat reckless one that was chosen.
Additional context
No response
Environment
Most applicable: I'm trying to upgrade to
kube v3.0.0kubectl version
Client Version: v1.33.4
Kustomize Version: v5.6.0
Server Version: v1.33.2+k3s1
Configuration and features
YAML
No response
Affected crates
No response
Would you like to work on fixing this bug?
None
Beta Was this translation helpful? Give feedback.
All reactions