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

chore: Remove unused rust dependencies #653

Merged
merged 2 commits into from
Sep 5, 2023

Conversation

diconico07
Copy link
Contributor

What this PR does / why we need it:
Clean-up dependencies by removing unused ones and moving test-only ones to dev-dependencies section

Special notes for your reviewer:

If applicable:

  • this PR has an associated PR with documentation in akri-docs
  • this PR contains unit tests
  • added code adheres to standard Rust formatting (cargo fmt)
  • code builds properly (cargo build)
  • code is free of common mistakes (cargo clippy)
  • all Akri tests succeed (cargo test)
  • inline documentation builds (cargo doc)
  • all commits pass the DCO bot check by being signed off -- see the failing DCO check for instructions on how to retroactively sign commits

Copy link
Contributor

@kate-goldenring kate-goldenring left a comment

Choose a reason for hiding this comment

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

Thank you @diconico07! What tool did you use to detect the unused deps? cargo tree?

@diconico07
Copy link
Contributor Author

I did it "manually" using RUSTFLAGS=-Wunused-crate-dependencies, on a cargo build then I removed all dependencies it called unused, then I re-added needed ones for tests and optional features as the compiler complained on cargo test and cargo build --all-features.
I looked for another way, using cargo-machete but the tool exposed lot of false positive.

Clean-up dependencies by removing unused ones and moving test-only ones
to dev-dependencies section

Signed-off-by: Nicolas Belouin <[email protected]>
@diconico07
Copy link
Contributor Author

/version patch

@github-actions github-actions bot added the version/patch Patch version change is needed label Sep 5, 2023
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
@diconico07 diconico07 merged commit db445cb into project-akri:main Sep 5, 2023
1 check passed
@diconico07 diconico07 deleted the prune-deps branch September 5, 2023 11:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
version/patch Patch version change is needed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants