Comment by PH95VuimJjqBqy
10 months ago
how does a dependency management system ensure the dependencies are there without doing dependency resolution?
10 months ago
how does a dependency management system ensure the dependencies are there without doing dependency resolution?
By separating the two. If there’s no Cargo.lock, resolution needs to be done, and the result is written out to the lock file. If the lock file is there, then you don’t need to re-run resolution, you just read out the result from the file.
The latency you’re arguing over is probably more to do with rustup selecting the right cargo and exec-ing that than dependency resolution. It’s heavier weight than it should be due to history reasons.
dealing with the Cargo.lock is a part of the dependency resolution.