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

Commiting the Cargo.lock #2071

Closed
happysalada opened this issue Mar 24, 2022 · 7 comments · Fixed by #2112
Closed

Commiting the Cargo.lock #2071

happysalada opened this issue Mar 24, 2022 · 7 comments · Fixed by #2112
Labels
enhancement New feature or request

Comments

@happysalada
Copy link
Contributor

Hi, could you commit the cargo.lock file please ?

The reason I am asking is that it is usually needed to build the software from source to package for other discributions.
I am currently having a look at packaging for nixos.

Let me know if you need more details.

@happysalada happysalada added the enhancement New feature or request label Mar 24, 2022
@houqp
Copy link
Member

houqp commented Mar 28, 2022

The general rule of thumb is to only checkin lock files for crates that produces binary artifacts. For example: datafusion-cli, ballista-scheduler, ballista-executor, etc. But we should avoid checking in lock file for the datafusion core itself since it's a library.

@happysalada
Copy link
Contributor Author

Right, I completely agree. I wanted to try out datafution-cli . Do you think you can commit the lockfile for it ?

@houqp
Copy link
Member

houqp commented Mar 28, 2022

adding a lockfile to datafusion-cli should be fine, you can generate one by running cargo build locally, then send a PR to have it checked it :)

@happysalada
Copy link
Contributor Author

happy to do an MR!
One more question though. Would you prefer a cargo lock in the datafusion-cli directory only for that project, or a global cargo.lock that would be added to the cargoignore. With the second way, everyone who develops on the repo would benefit from it.
Let me know what you prefer.

@houqp
Copy link
Member

houqp commented Mar 28, 2022

Thank you. Please put the lock file only in datafusion-cli folder so it won't get applied to the datafusion core library :)

@happysalada
Copy link
Contributor Author

like I said in the PR. unfortunately cargo does not tolerate a lock that is not at the root of the workspace.
So as a workaround I added exclude statements in the other cargo.toml files (for all the libraries).
Let me know.

@happysalada
Copy link
Contributor Author

Sorry, just have a follow up PR. By the time the first PR was merged, the lock had drifted
#2178

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants