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

Purposely fail to detect the license if multiple license files exist #114

Closed
benbalter opened this issue Sep 15, 2016 · 15 comments · Fixed by #202 or #203
Closed

Purposely fail to detect the license if multiple license files exist #114

benbalter opened this issue Sep 15, 2016 · 15 comments · Fixed by #202 or #203

Comments

@benbalter
Copy link
Contributor

benbalter commented Sep 15, 2016

E.g., I have license.cc0.txt and license.cc-by.txt both in the root of the repo.

We should bail due to the ambiguity.

@TheLastProject
Copy link

As an example of how messy it can get, I have an AGPLv3+ project that's currently detected as CC0: https://github.com/TheLastProject/mkblog.sh/.

@rmccue
Copy link

rmccue commented Oct 19, 2016

As another example of this, I have a LICENSE file with multiple licenses, which is currently detected as the latter (BSD 3-clause) rather than the primary (ISC): https://github.com/rmccue/Requests/blob/master/LICENSE

@stale stale bot added the wontfix label Apr 6, 2017
@stale
Copy link

stale bot commented Apr 6, 2017

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@TheLastProject
Copy link

Seriously? That's a horrible way to manage issues. In that case: bump (because you're forcing me to)

@stale
Copy link

stale bot commented Jun 5, 2017

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@TheLastProject
Copy link

Bump...

@ofek
Copy link

ofek commented Jun 10, 2017

@benbalter Are there plans to detect dual licenses? Many large projects are dual licensed for compatibility. Also, https://github.com/rust-lang/rust and almost everything written in it is MIT/Apache-2.0 but GitHub (licensee) can't detect it.

@mlinksva
Copy link
Contributor

@ofek licensee isn't detecting a license in rust-lang/rust due to its COPYRIGHT file which is higher priority than its LICENSE- files and doesn't match any license, not its multiple licenses.

If this (#114) issue were fixed, licensee wouldn't detect a license in rust-lang/rust even if the COPYRIGHT file weren't present.

I don't know if there are plans to detect dual licenses. It'd be nice to have. I wonder what false positives would be caused/would need to be mitigated as a result?

@ofek
Copy link

ofek commented Jun 10, 2017

@mlinksva Oh, I see.

What kind of false positives?

@mlinksva
Copy link
Contributor

@ofek one kind would be where a project's multiple license files aren't intended for offering the whole project under multiple licenses, but different parts of a project (eg code and content, project contributions and vendored material). If licensee detected multiple licenses for such a project, some or all of the reported licenses may be false for the project as a whole. I don't know how common this is, probably needs more investigation.

@ofek
Copy link

ofek commented Jun 10, 2017

@mlinksva Good point, thanks! Do you think detecting everything is worse than detecting none?

@mlinksva
Copy link
Contributor

@ofek probably. People seem to be more bothered by false positives than false negatives, and I'm pretty sympathetic to that. Detecting multiple licenses would be a significant change for licensee anyway, so I suppose that one approach might be to detect and report the existence of multiple license files, but not report that a repo is under any of those licenses.

@benbalter
Copy link
Contributor Author

WIP fix over in #203.

@ofek
Copy link

ofek commented Jun 22, 2017

@benbalter Fantastic!

@daira
Copy link

daira commented Jul 16, 2017

Example of licensee (via Github) misdetecting an Apache 2.0/MIT dual license as just Apache 2.0: zkcrypto/pairing#14

The project contains no LICENSE file, only LICENSE-APACHE and LICENSE-MIT. The README.md references both. So it seems to me that it is doing everything right to avoid being detected as Apache 2.0-only already.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
6 participants