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

Add support for cargo dependency renaming #55

Merged
merged 1 commit into from
Feb 10, 2025

Conversation

cottsay
Copy link
Member

@cottsay cottsay commented Feb 6, 2025

It is possible to reference a crate using an import name other than its package name. The package name and import name are typically the same, but when they differ, we should use the package name to construct the dependency graph. The import name is of no consequence outside of the package being built.

https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#renaming-dependencies-in-cargotoml

It is possible to reference a crate using an import name other than its
package name. The package name and import name are typically the same,
but when they differ, we should use the package name to construct the
dependency graph. The import name is of no consequence outside of the
package being built.
@cottsay cottsay self-assigned this Feb 6, 2025
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 68.75%. Comparing base (1c2882e) to head (0d43a49).

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #55      +/-   ##
==========================================
+ Coverage   68.63%   68.75%   +0.11%     
==========================================
  Files           7        7              
  Lines         271      272       +1     
  Branches       46       46              
==========================================
+ Hits          186      187       +1     
  Misses         56       56              
  Partials       29       29              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@mxgrey mxgrey left a comment

Choose a reason for hiding this comment

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

Great catch 👍

I'll mention this at the WG meeting today and then merge if there are no objections (which I can't imagine there will be).

@esteve
Copy link
Contributor

esteve commented Feb 10, 2025

@cottsay thanks!

@esteve esteve merged commit 05ef993 into main Feb 10, 2025
17 checks passed
@esteve esteve deleted the cottsay/renamed-dependencies branch February 10, 2025 13:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

4 participants