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

unsupported source protocol: sparse for key package.source #78

Open
g0hl1n opened this issue Aug 7, 2024 · 0 comments
Open

unsupported source protocol: sparse for key package.source #78

g0hl1n opened this issue Aug 7, 2024 · 0 comments

Comments

@g0hl1n
Copy link

g0hl1n commented Aug 7, 2024

Hi,
cargo-bitbake fails to parse Cargo files containing custom sparse registries:

$ cargo bitbake
error: failed to parse lock file at: /path/to/Cargo.lock

Caused by:
  unsupported source protocol: sparse for key `package.source`

Reproduction

An example Cargo.toml entry:

[dependencies]
foo = { version = "0.1.0", registry = "crates-dev-local" }

Which results in following Cargo.lock entry:

[[package]]
name = "foo"
version = "0.1.0"
source = "sparse+https://foo.jfrog.io/artifactory/api/cargo/crates-dev-local/index/"
checksum = "9228e13a0986a6ba12804284ae0ab68ad56f55f465338f99ab2ad44f5a7eec34"

Expected behavior

I would expect cargo-bitbake to translate this custom registry dependency to (the actual path must be retreived from the registry config):

SRC_URI += " \
  crate://foo.jfrog.io/artifactory/api/cargo/crates-dev-local/v1/crates/foo/0.1.0 \
"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant