Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disable unused default features of chrono crate #801

Merged
merged 1 commit into from
Jan 31, 2022

Conversation

dreamer
Copy link
Contributor

@dreamer dreamer commented Jan 31, 2022

Chrono crate has some default features that are not used by kube-rs;
by disabling them we can avoid pulling in time crate as dependency thus
trimming the dependency tree for all users and potentially speeding up
compilation time.

Signed-off-by: Patryk Obara dreamer.tan@gmail.com

Motivation

In the project I'm working on we want to get rid of unused time dependency. This dependency is almost always pulled-in via chrono crate (by optional default feature oldtime), but rarely anyone is using it. Almost all our dependencies already disable the default features on chrono - but kube-rs is the only exception I found so far. Turns out you don't use oldtime feature either.

Solution

Simply disable the default features :)

Chrono crate has some default features that are not used by kube-rs;
by disabling them we can avoid pulling in time crate as dependency thus
trimming the dependency tree for all users and potentially speeding up
compilation time.

Signed-off-by: Patryk Obara <dreamer.tan@gmail.com>
Copy link
Member

@nightkr nightkr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, LGTM!

@nightkr nightkr added the changelog-change changelog change category for prs label Jan 31, 2022
@codecov-commenter
Copy link

Codecov Report

Merging #801 (84f713d) into master (3381e69) will increase coverage by 0.02%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #801      +/-   ##
==========================================
+ Coverage   71.92%   71.94%   +0.02%     
==========================================
  Files          56       56              
  Lines        3775     3775              
==========================================
+ Hits         2715     2716       +1     
+ Misses       1060     1059       -1     
Impacted Files Coverage Δ
kube-runtime/src/wait.rs 70.00% <0.00%> (+2.00%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3381e69...84f713d. Read the comment docs.

@nightkr nightkr merged commit bfaea85 into kube-rs:master Jan 31, 2022
@clux clux added this to the 0.68.0 milestone Jan 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog-change changelog change category for prs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants