Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion crate_universe/src/context.rs
Original file line number Diff line number Diff line change
Expand Up @@ -412,7 +412,6 @@ mod test {
.map(|dep| (&dep.id, context.has_duplicate_workspace_member_dep_by_alias(dep)))
.collect::<Vec<_>>(),
[
(&CrateId::new("child".to_owned(), Version::new(0, 1, 0)), false),
(&CrateId::new("tonic".to_owned(), Version::new(0, 4, 3)), false),
(&CrateId::new("tonic-build".to_owned(), Version::new(0, 4, 2)), false),
],
Expand Down
13 changes: 3 additions & 10 deletions crate_universe/src/context/crate_context.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
//! Crate specific information embedded into [crate::context::Context] objects.

use std::collections::{BTreeMap, BTreeSet};
use std::str::FromStr;

use camino::Utf8PathBuf;
use cargo_metadata::{Node, Package, PackageId};
Expand Down Expand Up @@ -496,16 +497,8 @@ impl CrateContext {

let build_script_attrs = if let Some(target) = build_script_target {
// Track the build script dependency
common_attrs.deps.insert(
CrateDependency {
id: current_crate_id,
target: target.crate_name.clone(),
alias: None,
local_path: match source_annotations.get(&annotation.node.id) {
Some(SourceAnnotation::Path { path }) => Some(path.clone()),
_ => None,
},
},
common_attrs.extra_deps.insert(
Label::from_str(&format!(":{}", target.crate_name)).unwrap(),
None,
);

Expand Down