You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@buildstream.apache.org by GitBox <gi...@apache.org> on 2023/01/01 04:25:25 UTC
[GitHub] [buildstream-plugins] AdrianVovk commented on issue #44: cargo: Generate a Cargo.lock if one wasn't found
AdrianVovk commented on issue #44:
URL: https://github.com/apache/buildstream-plugins/issues/44#issuecomment-1368349610
> cargo-lock-generator only generates cargo.lock when tracking but otherwise does nothing
This is rather ugly, in [my experience](https://gitlab.com/carbonOS/build-meta/-/blob/main/plugins/gen-cargo-lock.py).
Here's how it ends up working out:
- if we generate the Cargo.lock file only during tracking, this ends up w/ a broken project for people who haven't tracked that element. Basically anyone who wants to be able to just clone & build will be unsuccessful because, simply, the Cargo.lock file doesn't exist!
- if we generate the Cargo.lock file during both tracking and fetching, the problem is that we cannot reliably generate an identical Cargo.lock file. Basically this would turn the fetching step into tracking, which breaks Buildstream again in a different way
- The only solution is to store the Cargo.lock file in the project ref. This is very ugly
Building this into the `cargo` plugin is optimal because it alleviates the need for the Cargo.lock file if not tracking
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@buildstream.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org