Skip to content
This repository has been archived by the owner on Sep 19, 2020. It is now read-only.

FC078 failure even though license is 'All Rights reserved' - FC 11.3 #657

Open
kidharb opened this issue Jul 27, 2017 · 12 comments
Open

FC078 failure even though license is 'All Rights reserved' - FC 11.3 #657

kidharb opened this issue Jul 27, 2017 · 12 comments

Comments

@kidharb
Copy link

kidharb commented Jul 27, 2017

This is related to Issue #609 and was seen on FC 11.2 and 11.3

$ foodcritic .
Checking 10 files
x.........
FC078: Ensure cookbook shared under an OSI-approved open source license: ./metadata.rb:1

$ foodcritic --version
foodcritic 11.3.0

$ cat metadata.rb | grep license
license 'All Rights Reserved'
@coderanger
Copy link
Contributor

Unless you have a .foodcritic file somehow re-enabling the rule, it should be off by default. The rule requires the use of an open-source license, and is mostly intended for use with the Supermarket cookbook quality check, you can disable it for cookbooks not intended to be open-source.

@kidharb
Copy link
Author

kidharb commented Jul 27, 2017

There is no .foodcritic file in my cookbook and
a foodcritic -l reveals that all rules FC001 - FC0092 are enabled.

@kidharb
Copy link
Author

kidharb commented Jul 27, 2017

Correction to above.
Not all rules are enabled.

FC0003, FC023, FC035, FC036 .... are disabled.

FC078 is enabled though.

@kidharb
Copy link
Author

kidharb commented Jul 27, 2017

I added an exception for FC078 in .foodcritic to work-around this issue for now.

@americanhanko
Copy link

americanhanko commented Sep 29, 2017

Same issue here. Here are the contents of my .foodcritic file, which resolved the issue for me:

$ cat .foodcritic
~FC078

@stefanwb
Copy link

I might be missing the point here but 'All Rights Reserved' is not an OSI-approved nor standardised license according to https://spdx.org/licenses/, is it?

@atheiman
Copy link

@stefanwb the point is why is that running against all cookbooks, it is expected this will fail for any enterprise internal cookbook

@sbrar7
Copy link

sbrar7 commented May 14, 2018

The issue still exists in the latest version12.3.0

@stefanwb
Copy link

@stefanwb the point is why is that running against all cookbooks, it is expected this will fail for any enterprise internal cookbook

Thanks for your repsonse. I did miss the point :)

However, shouldn't you run it with -t ~opensource for internal enterprise cookbooks then?

Also it seems dat FC069 does allow the 'All Rights Reserved' as a "license".. even though it is not.
So a better exclusion in this case might be -t ~license

@webchi
Copy link

webchi commented Nov 28, 2018

Still have it in 14.3.0

@Raboo
Copy link

Raboo commented Feb 19, 2019

It makes no sense in having a rule that forces people to do a exclusion for every internal/private cookbook. There are plenty of reasons for a cookbook to not be public, for instance being a wrapper cookbook.

I vote that if metadata contains any of the following

license          'All Rights Reserved'
privacy          true

then it should exclude FC0078

@Arpanbhagat5
Copy link

Upvote for @Raboo's proposal. 👍

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants