GithubHelp home page GithubHelp logo

Comments (5)

ethanpailes avatar ethanpailes commented on May 12, 2024 2

@eduardossampaio The typical pattern with cargo files is to check in Cargo.toml for libraries and checkin in both Cargo.toml and Cargo.lock for applications. Cargo.toml expresses the constraints you believe to describe the deps that work with the project which is good when you have a unknown number of consumers using your packages with their own dep constraints, while Cargo.lock describes a list of actual deps which is good when you want stability. Applications don't have any downstream consumers, so Cargo.lock should be checked in.

If deleting Cargo.lock fixed the build for you, your compiler version might be out of date with the project or there could just be a bug in the Cargo.lock file that needs to be fixed. Perhaps you could post the diff between the Cargo.lock that gets generated after you blow away the old one and the one that is checked in. That might show the issue.

from gameboy.

yazgoo avatar yazgoo commented on May 12, 2024 2

As mentioned by @ethanpailes, Cargo.lock should be kept, I think this issue can be closed (my 2 cts :) )

from gameboy.

mohanson avatar mohanson commented on May 12, 2024

The development spec I understand is that bin needs check-in Cargo.lock, See:

rust-lang/cargo#315 (comment)

from gameboy.

eduardossampaio avatar eduardossampaio commented on May 12, 2024

That is correct, but Cargo.lock is a generated file by build at first time. I'm suggesting to ignore it because build fails after I clone the project. The error disapeared after I delete the Cargo.lock file.

after removing cargolock

error Cargolock after git clone

from gameboy.

namibj avatar namibj commented on May 12, 2024

That is correct, but Cargo.lock is a generated file by build at first time. I'm suggesting to ignore it because build fails after I clone the project. The error disapeared after I delete the Cargo.lock file.

The problem is, that there is zero guarantee that cargo will be able to generate a working Cargo.lock file in the future. This is very pronounced with pre-1.0 crates and git-branch-references, as both aren't claiming any stability via SemVer.

from gameboy.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.