-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
license-file
without license
seems ill-advised
#8537
Comments
It looks like the "nonstandard" aspect was always known -- #974:
But there are good reasons to want |
Perhaps I'm misunderstanding the circumstance, but if a project is using a standard SPDX license, then it should fill in the Is the concern that someone will fill out the license-file when they should have filled in the license field because they are using a standard license? The documentation does try to make the distinction clear, but maybe it is not clear enough? I think the warning about setting both could definitely be clarified about which to use. |
Yes, this. I didn't know
Yes, I think that would help. However, I do think it's useful to have |
Right now, license and license-file are intentionally somewhat mutually exclusive, because license-file doesn't provide any semantics for how the license is used. If you write We talked about this in today's @rust-lang/cargo meeting. We agreed that we don't want Cargo to take on the responsibility of innovating in the area of software license specification. Instead, we'd prefer to delegate this to some existing standard. So, a few concrete proposals:
Based on all of that, we're going to close this issue for now. We care about seeing this solved, but we'd like to see an appropriate extension to SPDX expressions such that the expression in |
@joshtriplett can we at least clarify the warning as @ehuss suggested?
|
@cuviper Sure, I think clarifying that message would be reasonable. |
I went ahead and posted #9941 to add some detail to the warning message. |
Add some clarity on the license/license-file warning. As noted in #8537, there is some confusion about why license and license-file are mutually exclusive. This attempts to add some detail to the warning.
I want to specify I want to specify As things stand now, the manifest spec gives us no way to say "I'm using a standard license, and it's in this file" which would be useful to avoid having to guess whether it's going to be in |
Last I heard from a lawyer, the date isn't needed. The problem I realized with the name field is that, without copyright assignment, every contributor has a copyright claim on the source code and I was misrepresenting the copyright with just my name. So for me, that one line doesn't seem like a motivation to act on anything. I imagine we are still in the "wait for prior art / a standard" mode for this. |
Otherwise crates.io declares the license to be "non-standard" See rust-lang/cargo#8537
Problem
If you include both
license
andlicense-file
inCargo.toml
, you get a warning:cargo/src/cargo/util/toml/mod.rs
Lines 1311 to 1317 in aa68721
However, crates.io doesn't know how to describe an arbitrary
license-file
, so it ends up being called "non-standard", which is rather poor for the user. Maybe this could be considered a crates.io issue, but I don't think they should be expected to guess what the SPDX license is from a file. When multiple files are supported (#5933), it really can't know whether that should be AND or OR.For example, see the difference between pretty-git-prompt 0.2.0 and 0.2.1, which dropped the
license
field on cargo's recommendation.Steps
license
andlicense-file
$ cargo package
warning: only one of `license` or `license-file` is necessary
license-file
, crates.io calls the license "non-standard".Possible Solution(s)
I think maybe it should be a warning if only
license-file
is present, sincelicense
is better for providing SPDX to show on crates.io.Notes
Output of
cargo version
:And that warning is still on master as of aa68721, as linked above.
cc tokio-rs/tracing#842
The text was updated successfully, but these errors were encountered: